<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>Forem: Docker</title>
    <description>The latest articles on Forem by Docker (@docker).</description>
    <link>https://forem.com/docker</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Forganization%2Fprofile_image%2F3459%2F42b5911d-1b27-42a6-988a-a45d81aaaf7a.png</url>
      <title>Forem: Docker</title>
      <link>https://forem.com/docker</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://forem.com/feed/docker"/>
    <language>en</language>
    <item>
      <title>Seven Docker Tips Every Engineer Should Know (from Docker Captains)</title>
      <dc:creator>Mohammad-Ali A'RÂBI</dc:creator>
      <pubDate>Mon, 25 May 2026 07:25:00 +0000</pubDate>
      <link>https://forem.com/docker/seven-docker-tips-every-engineer-should-know-from-docker-captains-3o1h</link>
      <guid>https://forem.com/docker/seven-docker-tips-every-engineer-should-know-from-docker-captains-3o1h</guid>
      <description>&lt;p&gt;Between June and August 2025, Docker shared a short series of practical tips from Docker Captains on Twitter/X. The format was brief, but the advice is worth unpacking. This post is revisiting those seven tips with a little more context and newer examples.&lt;/p&gt;

&lt;p&gt;Here are the seven tips, in the chronological order they were shared!&lt;/p&gt;

&lt;h2&gt;
  
  
  1. Start New Projects with Docker Init
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Captain intro:&lt;/strong&gt; &lt;a href="https://www.docker.com/captains/mohammad-ali-arabi/" rel="noopener noreferrer"&gt;Mohammad-Ali A'rabi&lt;/a&gt; is a Docker Captain from Freiburg, Germany, a backend software engineer, Docker community leader, and the author of &lt;a href="https://www.dockersecurity.io/docker-and-kubernetes-security" rel="noopener noreferrer"&gt;&lt;em&gt;Docker and Kubernetes Security&lt;/em&gt;&lt;/a&gt;. His work often sits at the intersection of practical engineering, education, community, and secure-by-default container workflows.&lt;/p&gt;

&lt;p&gt;&lt;iframe class="tweet-embed" id="tweet-1934618217990754462-547" src="https://platform.twitter.com/embed/Tweet.html?id=1934618217990754462"&gt;
&lt;/iframe&gt;

  // Detect dark theme
  var iframe = document.getElementById('tweet-1934618217990754462-547');
  if (document.body.className.includes('dark-theme')) {
    iframe.src = "https://platform.twitter.com/embed/Tweet.html?id=1934618217990754462&amp;amp;theme=dark"
  }



&lt;/p&gt;

&lt;p&gt;The tweet points to &lt;code&gt;docker init&lt;/code&gt; as the fastest way to get a clean Docker setup for a new project:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker init
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The command analyzes your project and generates a set of files that follow Docker's best practices:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;code&gt;Dockerfile&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;.dockerignore&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;compose.yaml&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;README.Docker.md&lt;/code&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Read the following article for a detailed walkthrough of &lt;code&gt;docker init&lt;/code&gt; with a Java project: &lt;a href="https://www.dockersecurity.io/blog/dockerize-java-26-with-docker-init" rel="noopener noreferrer"&gt;Dockerize Java 26 with Docker Init&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  2. Clean Up Docker Disk Usage Carefully
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Captain intro:&lt;/strong&gt; &lt;a href="https://www.docker.com/contributors/rafael-pazini/" rel="noopener noreferrer"&gt;Rafael Pazini&lt;/a&gt; is a Docker Captain from Sao Paulo, Brazil, and a Senior Software Engineer at Pluto TV. He has more than 10 years of experience building scalable applications, with expertise in distributed systems, microservices, Docker, and Kubernetes.&lt;/p&gt;

&lt;p&gt;&lt;iframe class="tweet-embed" id="tweet-1937229925515252098-27" src="https://platform.twitter.com/embed/Tweet.html?id=1937229925515252098"&gt;
&lt;/iframe&gt;

  // Detect dark theme
  var iframe = document.getElementById('tweet-1937229925515252098-27');
  if (document.body.className.includes('dark-theme')) {
    iframe.src = "https://platform.twitter.com/embed/Tweet.html?id=1937229925515252098&amp;amp;theme=dark"
  }



&lt;/p&gt;

&lt;p&gt;The command &lt;code&gt;docker system prune&lt;/code&gt; is no stranger to Docker users:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker system prune &lt;span class="nt"&gt;-a&lt;/span&gt; &lt;span class="nt"&gt;--volumes&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The terminal will say:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;WARNING! This will remove:
  - all stopped containers
  - all networks not used by at least one container
  - all dangling images
  - unused build cache

Are you sure you want to continue? [y/N]
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;BTW, did you know &lt;code&gt;[y/N]&lt;/code&gt; means "default to No if the user just presses Enter"?&lt;/p&gt;

&lt;p&gt;The &lt;code&gt;-a&lt;/code&gt; flag removes &lt;em&gt;all&lt;/em&gt; unused images, not just dangling ones. The &lt;code&gt;--volumes&lt;/code&gt; flag adds unused volumes to the cleanup list. Check it out, and the warning verifies it:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;WARNING! This will remove:
  - all stopped containers
  - all networks not used by at least one container
  - all anonymous volumes not used by at least one container
  - all images without at least one container associated to them
  - all build cache

Are you sure you want to continue? [y/N]
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;A few more handy commands:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker rmi &lt;span class="nt"&gt;-f&lt;/span&gt; &lt;span class="si"&gt;$(&lt;/span&gt;docker images &lt;span class="nt"&gt;-q&lt;/span&gt;&lt;span class="si"&gt;)&lt;/span&gt;  &lt;span class="c"&gt;# Force-remove all images&lt;/span&gt;
docker volume &lt;span class="nb"&gt;rm&lt;/span&gt; &lt;span class="si"&gt;$(&lt;/span&gt;docker volume &lt;span class="nb"&gt;ls&lt;/span&gt; &lt;span class="nt"&gt;-q&lt;/span&gt;&lt;span class="si"&gt;)&lt;/span&gt;  &lt;span class="c"&gt;# Remove all volumes&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Satisfaction!&lt;/p&gt;

&lt;h2&gt;
  
  
  3. Use Multi-Stage Builds
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Captain intro:&lt;/strong&gt; &lt;a href="https://www.docker.com/captains/karan-verma/" rel="noopener noreferrer"&gt;Karan Verma&lt;/a&gt; is a Docker Captain from Jalandhar, India. He is a software engineer and community leader who has been active in the Docker community in Jalandhar since 2017, with a focus that includes AI and MLOps.&lt;/p&gt;

&lt;p&gt;&lt;iframe class="tweet-embed" id="tweet-1939768473887916538-62" src="https://platform.twitter.com/embed/Tweet.html?id=1939768473887916538"&gt;
&lt;/iframe&gt;

  // Detect dark theme
  var iframe = document.getElementById('tweet-1939768473887916538-62');
  if (document.body.className.includes('dark-theme')) {
    iframe.src = "https://platform.twitter.com/embed/Tweet.html?id=1939768473887916538&amp;amp;theme=dark"
  }



&lt;/p&gt;

&lt;p&gt;It's not only AI images that can get big. It's better to trim images down, AI or not. It's cost-effective, faster to deploy, and more secure by reducing the attack surface. Multi-stage builds are the way to go for that.&lt;/p&gt;

&lt;p&gt;To add to that, &lt;code&gt;docker init&lt;/code&gt; already generates a multi-stage Dockerfile for you.&lt;/p&gt;

&lt;p&gt;Also, make sure the final stage is hardened with a non-root user and limited privileges. For example, use a base image with no package manager, no shell, and no extra tools.&lt;/p&gt;

&lt;p&gt;Another important tip is to generate SBOM attestations during the build:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker build &lt;span class="nt"&gt;--sbom&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nb"&gt;true&lt;/span&gt; &lt;span class="nt"&gt;-t&lt;/span&gt; my-image:latest &lt;span class="nb"&gt;.&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This command doesn't automatically include all stages in the SBOM, so you need to add the following line to each stage in your Dockerfile to ensure they are included:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight docker"&gt;&lt;code&gt;&lt;span class="k"&gt;ARG&lt;/span&gt;&lt;span class="s"&gt; BUILDKIT_SBOM_SCAN_CONTEXT=true&lt;/span&gt;
&lt;span class="k"&gt;FROM&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;lt;image&amp;gt;&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;AS&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;stage&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  4. Choose Lightweight, Version-Pinned Base Images
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Captain intro:&lt;/strong&gt; &lt;a href="https://www.docker.com/contributors/sergio-lopes/" rel="noopener noreferrer"&gt;Sergio Lopes&lt;/a&gt; is a Docker Captain from Sao Paulo, Brazil, and a Principal Backend Engineer at Banco Itau Unibanco S.A. Docker highlights his long backend engineering background and expertise in developer productivity, Kubernetes, modern application development, and observability.&lt;/p&gt;

&lt;p&gt;&lt;iframe class="tweet-embed" id="tweet-1944758785475498198-694" src="https://platform.twitter.com/embed/Tweet.html?id=1944758785475498198"&gt;
&lt;/iframe&gt;

  // Detect dark theme
  var iframe = document.getElementById('tweet-1944758785475498198-694');
  if (document.body.className.includes('dark-theme')) {
    iframe.src = "https://platform.twitter.com/embed/Tweet.html?id=1944758785475498198&amp;amp;theme=dark"
  }



&lt;/p&gt;

&lt;p&gt;This tweet is from July 2025, but the advice is evergreen. Use Docker Hardened Images (DHI) for base images, and pin to a specific version. The DHI are:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Lightweight&lt;/li&gt;
&lt;li&gt;Open-source&lt;/li&gt;
&lt;li&gt;Secure-by-default&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Check the catalog at &lt;a href="https://dhi.io" rel="noopener noreferrer"&gt;dhi.io&lt;/a&gt; and pick the right image for your language and use case. Search for "node", get into the &lt;a href="https://hub.docker.com/hardened-images/catalog/dhi/node" rel="noopener noreferrer"&gt;Node.js image catalog&lt;/a&gt;:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fr0ms7meghy1vt90ky3p7.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fr0ms7meghy1vt90ky3p7.png" alt="DHI Node.js Catalog" width="799" height="363"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Then go to the "Images" tab to see &lt;a href="https://hub.docker.com/hardened-images/catalog/dhi/node/images" rel="noopener noreferrer"&gt;the full list&lt;/a&gt;:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ff2iifvjnl9thpkwbffw7.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ff2iifvjnl9thpkwbffw7.png" alt="DHI Node.js Images" width="800" height="342"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;In the list of images:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;If there is a lock, it's not free to use. Just skip it.&lt;/li&gt;
&lt;li&gt;There are Debian and Alpine variants.&lt;/li&gt;
&lt;li&gt;There are "dev" variants with build tools and "prod" variants without them.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Find a version, and your Dockerfile should start like this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight docker"&gt;&lt;code&gt;&lt;span class="c"&gt;# The build stage&lt;/span&gt;
&lt;span class="k"&gt;FROM&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;dhi.io/node:26.2.0-debian13-dev&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;AS&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;build&lt;/span&gt;

&lt;span class="c"&gt;# The production stage&lt;/span&gt;
&lt;span class="k"&gt;FROM&lt;/span&gt;&lt;span class="s"&gt; dhi.io/node:26.2.0-debian13&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The dev image has 10 CVEs and the prod image has 0.&lt;/p&gt;

&lt;h2&gt;
  
  
  5. Use Docker Scout Quickview
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Captain intro:&lt;/strong&gt; &lt;a href="https://www.docker.com/contributors/khushboo-verma/" rel="noopener noreferrer"&gt;Khushboo Verma&lt;/a&gt; is a Docker Captain and Platform Engineer at Appwrite in Bengaluru, India. She is also a community builder and speaker, with Docker listing her expertise in developer productivity, modern application development, and observability.&lt;/p&gt;

&lt;p&gt;&lt;iframe class="tweet-embed" id="tweet-1947370272115290448-318" src="https://platform.twitter.com/embed/Tweet.html?id=1947370272115290448"&gt;
&lt;/iframe&gt;

  // Detect dark theme
  var iframe = document.getElementById('tweet-1947370272115290448-318');
  if (document.body.className.includes('dark-theme')) {
    iframe.src = "https://platform.twitter.com/embed/Tweet.html?id=1947370272115290448&amp;amp;theme=dark"
  }



&lt;/p&gt;

&lt;p&gt;The &lt;code&gt;docker scout quickview&lt;/code&gt; command is a fast way to get a snapshot of your image's security posture. It checks for known CVEs, lists dependencies, and provides metadata about the base image. This is especially useful in CI pipelines to catch vulnerabilities before pushing images to a registry.&lt;/p&gt;

&lt;p&gt;Let's do it on the DHI Node.js image:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker scout quickview dhi.io/node:26.2.0-debian13
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The output says:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;    i New version 1.21.0 available (installed version is 1.20.3) at https://github.com/docker/scout-cli
    ✓ SBOM obtained from attestation, 20 packages found
    ✓ Provenance obtained from attestation
    ✓ VEX statements obtained from attestation

    i Base image was auto-detected. To get more accurate results, build images with max-mode provenance attestations.
      Review docs.docker.com ↗ for more information.

 Target   │  dhi.io/node:26.2.0-debian13  │    0C     0H     0M     0L
   digest │  f3fb2a06abd6                 │
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;So, there are no CVEs, and the image has:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;SBOM attestation with 20 packages&lt;/li&gt;
&lt;li&gt;Provenance attestation&lt;/li&gt;
&lt;li&gt;VEX statements attestation&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If you want to learn more about these concepts, check out the Docker Commandos workshop on Docker Labspaces: &lt;a href="https://www.dockersecurity.io/commandos" rel="noopener noreferrer"&gt;Docker Commandos&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  6. Use .dockerignore
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Captain intro:&lt;/strong&gt; &lt;a href="https://www.docker.com/captains/anjan-kumar-reddy-ayyadapu/" rel="noopener noreferrer"&gt;Anjan Kumar Reddy Ayyadapu&lt;/a&gt; is a Docker Captain and Senior Architect Solution Leader at Cloudera Inc. Docker lists his expertise across AI/ML, CI/CD, Kubernetes, observability, developer productivity, and software secure supply chain work.&lt;/p&gt;

&lt;p&gt;&lt;iframe class="tweet-embed" id="tweet-1950295464433025395-539" src="https://platform.twitter.com/embed/Tweet.html?id=1950295464433025395"&gt;
&lt;/iframe&gt;

  // Detect dark theme
  var iframe = document.getElementById('tweet-1950295464433025395-539');
  if (document.body.className.includes('dark-theme')) {
    iframe.src = "https://platform.twitter.com/embed/Tweet.html?id=1950295464433025395&amp;amp;theme=dark"
  }



&lt;/p&gt;

&lt;p&gt;The tweet compares &lt;code&gt;.dockerignore&lt;/code&gt; to &lt;code&gt;.gitignore&lt;/code&gt;, which is exactly the right mental model. &lt;code&gt;.gitignore&lt;/code&gt; decides what should not enter version control; &lt;code&gt;.dockerignore&lt;/code&gt; decides what should not enter the Docker build context.&lt;/p&gt;

&lt;p&gt;Two points on that!&lt;/p&gt;

&lt;p&gt;When doing a &lt;code&gt;docker build&lt;/code&gt; command, it usually looks like this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker build &lt;span class="nt"&gt;-t&lt;/span&gt; my-image:latest &lt;span class="nb"&gt;.&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The &lt;code&gt;.&lt;/code&gt; at the end is not the Dockerfile path; it's the build context path. It means, "send the current directory and all its contents to the Docker daemon for the build".&lt;/p&gt;

&lt;p&gt;Anjan says &lt;em&gt;blacklist&lt;/em&gt; some files with &lt;code&gt;.dockerignore&lt;/code&gt;, I would say &lt;em&gt;whitelist&lt;/em&gt; some files with &lt;code&gt;.dockerignore&lt;/code&gt;. Start with a clean slate, and add only what you need. For example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;# .dockerignore
*

!src/
!package.json
!package-lock.json
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  7. Limit Container Privileges
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Captain intro:&lt;/strong&gt; &lt;a href="https://www.docker.com/captains/mohammad-ali-arabi/" rel="noopener noreferrer"&gt;Mohammad-Ali A'rabi&lt;/a&gt; appears again in Docker's series, this time with a security tip. It's not me promoting myself, it's Docker!&lt;/p&gt;

&lt;p&gt;&lt;iframe class="tweet-embed" id="tweet-1953561787623788652-733" src="https://platform.twitter.com/embed/Tweet.html?id=1953561787623788652"&gt;
&lt;/iframe&gt;

  // Detect dark theme
  var iframe = document.getElementById('tweet-1953561787623788652-733');
  if (document.body.className.includes('dark-theme')) {
    iframe.src = "https://platform.twitter.com/embed/Tweet.html?id=1953561787623788652&amp;amp;theme=dark"
  }



&lt;/p&gt;

&lt;p&gt;Just for context: Linux capabilities are granular permissions that can be independently enabled or disabled for processes. Similar to the whitelisting approach of &lt;code&gt;.dockerignore&lt;/code&gt;, you can start with a clean slate by dropping all capabilities and then adding only the ones your application needs. For example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker run &lt;span class="nt"&gt;--cap-drop&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;ALL &lt;span class="nt"&gt;--cap-add&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;NET_ADMIN my-image:latest
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It's similar in a Kubernetes pod spec:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight yaml"&gt;&lt;code&gt;&lt;span class="na"&gt;apiVersion&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;v1&lt;/span&gt;
&lt;span class="na"&gt;kind&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;Pod&lt;/span&gt;
&lt;span class="na"&gt;metadata&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
  &lt;span class="na"&gt;name&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;my-pod&lt;/span&gt;
&lt;span class="na"&gt;spec&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
  &lt;span class="na"&gt;containers&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
    &lt;span class="pi"&gt;-&lt;/span&gt; &lt;span class="na"&gt;name&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;my-container&lt;/span&gt;
      &lt;span class="na"&gt;image&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;my-image:latest&lt;/span&gt;
      &lt;span class="na"&gt;securityContext&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
        &lt;span class="na"&gt;capabilities&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
          &lt;span class="na"&gt;drop&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="pi"&gt;[&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="s"&gt;ALL"&lt;/span&gt;&lt;span class="pi"&gt;]&lt;/span&gt;
          &lt;span class="na"&gt;add&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="pi"&gt;[&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="s"&gt;NET_ADMIN"&lt;/span&gt;&lt;span class="pi"&gt;]&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;To learn more about Linux capabilities and how to use them in Docker and Kubernetes, check out the book &lt;a href="https://www.dockersecurity.io/docker-and-kubernetes-security" rel="noopener noreferrer"&gt;Docker and Kubernetes Security&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;I wish Docker starts sharing more tips from Docker Captains, and I hope this post helps expand on the original tweets with more context and examples. If you have any questions or want to share your own Docker tips, feel free to reach out on &lt;a href="https://www.linkedin.com/in/aerabi/" rel="noopener noreferrer"&gt;LinkedIn&lt;/a&gt; or &lt;a href="https://x.com/MohammadAliEN" rel="noopener noreferrer"&gt;Twitter/X&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Happy Dockerizing!&lt;/p&gt;

</description>
      <category>docker</category>
    </item>
    <item>
      <title>Book Review: Operational AI with Docker</title>
      <dc:creator>Mohammad-Ali A'RÂBI</dc:creator>
      <pubDate>Wed, 20 May 2026 07:32:00 +0000</pubDate>
      <link>https://forem.com/docker/book-review-operational-ai-with-docker-73d</link>
      <guid>https://forem.com/docker/book-review-operational-ai-with-docker-73d</guid>
      <description>&lt;p&gt;In my &lt;a href="https://www.dockersecurity.io/blog/docker-read-list-2026-q1" rel="noopener noreferrer"&gt;Q1 2026 Docker Read List&lt;/a&gt;, I dropped a little hint that I was involved in reviewing an exciting upcoming book for Q2. Well, the secret is finally out! I had the absolute honor of being a technical reviewer for &lt;em&gt;Operational AI with Docker&lt;/em&gt;, written by my friends and fellow experts &lt;strong&gt;Ajeet Singh Raina&lt;/strong&gt; and &lt;strong&gt;Harsh Manvar&lt;/strong&gt;.&lt;/p&gt;


&lt;div class="crayons-card c-embed text-styles text-styles--secondary"&gt;
    &lt;div class="c-embed__content"&gt;
        &lt;div class="c-embed__cover"&gt;
          &lt;a href="https://www.dockersecurity.io/blog/docker-read-list-2026-q1" class="c-link align-middle" rel="noopener noreferrer"&gt;
            &lt;img alt="" src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fwww.dockersecurity.io%2Fblog-img%2Fdocker-read-list-2026-q1.png" height="447" class="m-0" width="800"&gt;
          &lt;/a&gt;
        &lt;/div&gt;
      &lt;div class="c-embed__body"&gt;
        &lt;h2 class="fs-xl lh-tight"&gt;
          &lt;a href="https://www.dockersecurity.io/blog/docker-read-list-2026-q1" rel="noopener noreferrer" class="c-link"&gt;
            The Complete Docker Read List: Q1 2026 Edition - Docker and Kubernetes Security - Docker and Kubernetes Security
          &lt;/a&gt;
        &lt;/h2&gt;
          &lt;p class="truncate-at-3"&gt;
            A curated reading list of the best books on Docker and Kubernetes for the first quarter of 2026, featuring releases from Docker Captains and industry experts.
          &lt;/p&gt;
        &lt;div class="color-secondary fs-s flex items-center"&gt;
            &lt;img alt="favicon" class="c-embed__favicon m-0 mr-2 radius-0" src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fwww.dockersecurity.io%2Ffavicon.ico" width="48" height="48"&gt;
          dockersecurity.io
        &lt;/div&gt;
      &lt;/div&gt;
    &lt;/div&gt;
&lt;/div&gt;


&lt;p&gt;I love a good narrative in my technical books. The authors definitely brought some drama to the text, which I absolutely loved about this book. I had the chance to review the last four chapters of the book, and would love to share some exclusive behind-the-scenes insights about the book, as well as my thoughts on it.&lt;/p&gt;

&lt;h2&gt;
  
  
  Authors
&lt;/h2&gt;

&lt;p&gt;Well, the authors need no introduction, but I'll still give you one.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Ajeet Singh Raina&lt;/strong&gt; was a Docker Captain for six years until he was hired by Docker as a Developer Advocate. He was my first point of contact when I started my journey in the Docker community, and we published three blog posts together on the Docker blog. He is an absolute legend, the man behind the Collabnix Community, and a great mentor to many in the container ecosystem.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Harsh Manvar&lt;/strong&gt; is a Senior Software Engineer at Oracle, a Docker Captain, and a CNCF Ambassador. Similarly, he is also an absolute star in the Indian container ecosystem, and has been a great mentor to many in the community. I had the pleasure of meeting him in person at the Docker Captains Summit in 2025, when he shared with me his plans for the book, and I was immediately excited about it.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Book's Final Act: From MCP to KAgent
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Chapter 6&lt;/strong&gt;. The authors introduced the &lt;em&gt;Docker MCP Gateway&lt;/em&gt; flawlessly. Before getting into the details, they did a great job of setting the stage by showing exactly why we need a gateway, and why it is painful to connect different MCP servers directly. It's great that the authors let you feel the pain, instead of just telling you about it.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Chapters 7 and 8&lt;/strong&gt;. These chapters dive heavily into using AI agents and orchestrating multiple AI agents using Python. The chapters are packed with multiple examples and Docker Compose projects. The chapters might feel a bit overwhelming or tedious for readers, but it perfectly shows how one can use AI agents in a real-world scenario, and create a complex system that can solve a problem end-to-end. These two chapters are practically every Hollywood movie 70 minutes in, when it feels we're at impossible odds, and there is no way out.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Chapter 9&lt;/strong&gt;. The grand finale covers Docker Sandboxes, Docker Agent, and KAgent. Let me tell you, this is an awesome way to end the book. It suddenly becomes clear that any pain we had to endure in Chapter 8 was entirely intentional: it was just to make the out-of-the-box experience of Docker Agent and KAgent shine! Suddenly eagles come and Frodo is on his way to Valinor!&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Final Thoughts
&lt;/h2&gt;

&lt;p&gt;The book is purely practical, impossibly fresh, and skillfully dramatic. It teaches you the basics and the advanced features of Docker MCP, Docker Agent, and KAgent. It lets you feel the pain and the joy of better tools. It is a must-read for anyone interested in the future of AI and how it can be operationalized using Docker. It's a great read, sometimes a bit overwhelming, but always rewarding. You need it in your library, and you need to read it.&lt;/p&gt;

</description>
      <category>docker</category>
      <category>ai</category>
      <category>books</category>
    </item>
    <item>
      <title>Generating SBOM with Docker Scout</title>
      <dc:creator>Mohammad-Ali A'RÂBI</dc:creator>
      <pubDate>Thu, 23 Apr 2026 18:40:34 +0000</pubDate>
      <link>https://forem.com/docker/generating-sbom-with-docker-scout-27eg</link>
      <guid>https://forem.com/docker/generating-sbom-with-docker-scout-27eg</guid>
      <description>&lt;p&gt;Knowing what's inside your container is the first step to securing it. In the first commando mission, we dockerized a Java 26 project using Docker Init. Now that we have an image, it's time to see what's actually in it.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Mission: Who Lives in Asgard?
&lt;/h2&gt;

&lt;p&gt;Rothütle, the tactician of the Docker Commandos, asks Thor for a list of all Asgard residents. Why? Because you can't defend a city if you don't know who's inside. By getting this list, you can later cross-reference it with known threats and identify the shadows in disguise.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F4p1st5ec20jpfc3nbc93.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F4p1st5ec20jpfc3nbc93.png" alt="Rothütle asking for the SBOM" width="800" height="537"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Technical Requirements
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Docker Desktop that is not too old, or&lt;/li&gt;
&lt;li&gt;Docker Scout CLI plugin installed.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;To make sure you have the Docker Scout plugin, run:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker scout &lt;span class="nt"&gt;--help&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Generate the SBOM
&lt;/h2&gt;

&lt;p&gt;We'll use &lt;code&gt;docker scout sbom&lt;/code&gt; to peek inside our image. If you followed the previous post, you have an image built from your project. Let's assume you tagged it &lt;code&gt;hello-wowlrd:latest&lt;/code&gt;.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker scout sbom hello-wowlrd:latest &lt;span class="nt"&gt;--format&lt;/span&gt; list
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The &lt;code&gt;--format list&lt;/code&gt; flag gives you a clean table of all the packages, their versions, and types (e.g., &lt;code&gt;deb&lt;/code&gt;, &lt;code&gt;maven&lt;/code&gt;).&lt;/p&gt;

&lt;h2&gt;
  
  
  Exporting to Standard Formats
&lt;/h2&gt;

&lt;p&gt;While a table is great for humans, tools prefer standard formats like SPDX or CycloneDX. Let's export our SBOM to a JSON file using the SPDX format:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker scout sbom hello-wowlrd:latest &lt;span class="nt"&gt;--format&lt;/span&gt; spdx &lt;span class="nt"&gt;--output&lt;/span&gt; sbom.spdx.json
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;If you investigate the file, you will see a detailed inventory:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;jq &lt;span class="nb"&gt;.&lt;/span&gt; sbom.spdx.json | less
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This file contains every package, its version, and its license—perfect for compliance and automated scanning. You can check available formats by running &lt;code&gt;docker scout sbom --help&lt;/code&gt;. Try exporting in CycloneDX format and compare it with the SPDX output!&lt;/p&gt;

&lt;h2&gt;
  
  
  Exercise: Comparing Base Images
&lt;/h2&gt;

&lt;p&gt;One of the best ways to understand the value of an SBOM is to compare different base images. For example, let's look at the difference between a standard Node.js image and its Alpine counterpart:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker scout sbom node:25 &lt;span class="nt"&gt;--format&lt;/span&gt; list
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Versus:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker scout sbom node:25-alpine &lt;span class="nt"&gt;--format&lt;/span&gt; list
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You'll notice that the Alpine version is significantly smaller, with fewer packages. This is why "minimal base images" are a core tenet of container security—fewer residents mean fewer places for CVE monsters to hide.&lt;/p&gt;

&lt;h2&gt;
  
  
  What's Next?
&lt;/h2&gt;

&lt;p&gt;Now that we have our list of residents, the next mission is to find the monsters. In the next post, we'll use Docker Scout to scan for CVEs.&lt;/p&gt;

&lt;p&gt;Want the full mission? Visit &lt;a href="https://dev.to/commandos"&gt;Docker Commandos&lt;/a&gt; or &lt;a href="https://dev.to/contact"&gt;request a workshop&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>docker</category>
      <category>commandos</category>
    </item>
    <item>
      <title>Dockerizing a Java 26 Project with Docker Init</title>
      <dc:creator>Mohammad-Ali A'RÂBI</dc:creator>
      <pubDate>Tue, 31 Mar 2026 13:56:57 +0000</pubDate>
      <link>https://forem.com/docker/dockerizing-a-java-26-project-with-docker-init-2agp</link>
      <guid>https://forem.com/docker/dockerizing-a-java-26-project-with-docker-init-2agp</guid>
      <description>&lt;p&gt;Docker Init was introduced in Docker Desktop 4.27, before LLMs became the default answer to everything. It's a "smart" interactive wizard that analyzes your project and generates:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;A &lt;code&gt;Dockerfile&lt;/code&gt; (multi-stage, production-ready)&lt;/li&gt;
&lt;li&gt;A &lt;code&gt;compose.yaml&lt;/code&gt; file&lt;/li&gt;
&lt;li&gt;A &lt;code&gt;.dockerignore&lt;/code&gt; file&lt;/li&gt;
&lt;li&gt;A &lt;code&gt;README.Docker.md&lt;/code&gt; with build and run instructions&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;What makes it valuable is that it's deterministic—not a probabilistic guess. It produces the same correct output every time, following Docker's own best practices.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fk3zwizuxt2dwpgs2qufj.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fk3zwizuxt2dwpgs2qufj.png" alt="Docker Commandos setting up the command center" width="800" height="597"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Technical Requirements
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Docker Desktop 4.27 or later&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Create a New Project
&lt;/h2&gt;

&lt;p&gt;I'm using a Spring Boot project. Because it's early Spring now and I haven't touched one in a while—so let's go.&lt;/p&gt;

&lt;p&gt;Head to &lt;a href="https://start.spring.io/" rel="noopener noreferrer"&gt;start.spring.io&lt;/a&gt; and create a project with:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Project:&lt;/strong&gt; Maven&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Language:&lt;/strong&gt; Java&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Spring Boot:&lt;/strong&gt; 4.0.5 &lt;em&gt;(or whatever the latest stable is)&lt;/em&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Packaging:&lt;/strong&gt; Jar&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Java:&lt;/strong&gt; 26&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;I used these coordinates, but pick your own:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Group:&lt;/strong&gt; io.dockersecurity&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Artifact:&lt;/strong&gt; hello-wowlrd&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Package Name:&lt;/strong&gt; io.dockersecurity.hello-wowlrd&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Download, unzip, and step into the directory:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;cd &lt;/span&gt;hello-wowlrd
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Run Docker Init
&lt;/h2&gt;

&lt;p&gt;As my British friend say, "It's Docker, innit?"&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker init
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The interactive wizard detects your Java project automatically. Accept "Java", confirm the source directory and Java version, and enter the port:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;? What application platform does your project use? Java
? What's the relative directory (with a leading .) for your app? ./src
? What version of Java do you want to use? 26
? What port does your server listen on? 8080
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Docker Init generates four files. The one that matters most is the &lt;code&gt;Dockerfile&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight docker"&gt;&lt;code&gt;&lt;span class="c"&gt;# syntax=docker/dockerfile:1&lt;/span&gt;

&lt;span class="c"&gt;################################################################################&lt;/span&gt;
&lt;span class="c"&gt;# Stage 1: resolve and download dependencies&lt;/span&gt;
&lt;span class="k"&gt;FROM&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;eclipse-temurin:26-jdk-jammy&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;as&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;deps&lt;/span&gt;

&lt;span class="k"&gt;WORKDIR&lt;/span&gt;&lt;span class="s"&gt; /build&lt;/span&gt;

&lt;span class="k"&gt;COPY&lt;/span&gt;&lt;span class="s"&gt; --chmod=0755 mvnw mvnw&lt;/span&gt;
&lt;span class="k"&gt;COPY&lt;/span&gt;&lt;span class="s"&gt; .mvn/ .mvn/&lt;/span&gt;

&lt;span class="k"&gt;RUN &lt;/span&gt;&lt;span class="nt"&gt;--mount&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nb"&gt;type&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nb"&gt;bind&lt;/span&gt;,source&lt;span class="o"&gt;=&lt;/span&gt;pom.xml,target&lt;span class="o"&gt;=&lt;/span&gt;pom.xml &lt;span class="se"&gt;\
&lt;/span&gt;    &lt;span class="nt"&gt;--mount&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nb"&gt;type&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;cache,target&lt;span class="o"&gt;=&lt;/span&gt;/root/.m2 ./mvnw dependency:go-offline &lt;span class="nt"&gt;-DskipTests&lt;/span&gt;

&lt;span class="c"&gt;################################################################################&lt;/span&gt;
&lt;span class="c"&gt;# Stage 2: build the application&lt;/span&gt;
&lt;span class="k"&gt;FROM&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;deps&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;as&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;package&lt;/span&gt;

&lt;span class="k"&gt;WORKDIR&lt;/span&gt;&lt;span class="s"&gt; /build&lt;/span&gt;

&lt;span class="k"&gt;COPY&lt;/span&gt;&lt;span class="s"&gt; ./src src/&lt;/span&gt;
&lt;span class="k"&gt;RUN &lt;/span&gt;&lt;span class="nt"&gt;--mount&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nb"&gt;type&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nb"&gt;bind&lt;/span&gt;,source&lt;span class="o"&gt;=&lt;/span&gt;pom.xml,target&lt;span class="o"&gt;=&lt;/span&gt;pom.xml &lt;span class="se"&gt;\
&lt;/span&gt;    &lt;span class="nt"&gt;--mount&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nb"&gt;type&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;cache,target&lt;span class="o"&gt;=&lt;/span&gt;/root/.m2 &lt;span class="se"&gt;\
&lt;/span&gt;    ./mvnw package &lt;span class="nt"&gt;-DskipTests&lt;/span&gt; &lt;span class="o"&gt;&amp;amp;&amp;amp;&lt;/span&gt; &lt;span class="se"&gt;\
&lt;/span&gt;    &lt;span class="nb"&gt;mv &lt;/span&gt;target/&lt;span class="si"&gt;$(&lt;/span&gt;./mvnw &lt;span class="nb"&gt;help&lt;/span&gt;:evaluate &lt;span class="nt"&gt;-Dexpression&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;project.artifactId &lt;span class="nt"&gt;-q&lt;/span&gt; &lt;span class="nt"&gt;-DforceStdout&lt;/span&gt;&lt;span class="si"&gt;)&lt;/span&gt;-&lt;span class="si"&gt;$(&lt;/span&gt;./mvnw &lt;span class="nb"&gt;help&lt;/span&gt;:evaluate &lt;span class="nt"&gt;-Dexpression&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;project.version &lt;span class="nt"&gt;-q&lt;/span&gt; &lt;span class="nt"&gt;-DforceStdout&lt;/span&gt;&lt;span class="si"&gt;)&lt;/span&gt;.jar target/app.jar

&lt;span class="c"&gt;################################################################################&lt;/span&gt;
&lt;span class="c"&gt;# Stage 3: extract Spring Boot layers&lt;/span&gt;
&lt;span class="k"&gt;FROM&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;package&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;as&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;extract&lt;/span&gt;

&lt;span class="k"&gt;WORKDIR&lt;/span&gt;&lt;span class="s"&gt; /build&lt;/span&gt;

&lt;span class="k"&gt;RUN &lt;/span&gt;java &lt;span class="nt"&gt;-Djarmode&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;layertools &lt;span class="nt"&gt;-jar&lt;/span&gt; target/app.jar extract &lt;span class="nt"&gt;--destination&lt;/span&gt; target/extracted

&lt;span class="c"&gt;################################################################################&lt;/span&gt;
&lt;span class="c"&gt;# Stage 4: minimal runtime image&lt;/span&gt;
&lt;span class="k"&gt;FROM&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;eclipse-temurin:26-jre-jammy&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;AS&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;final&lt;/span&gt;

&lt;span class="k"&gt;ARG&lt;/span&gt;&lt;span class="s"&gt; UID=10001&lt;/span&gt;
&lt;span class="k"&gt;RUN &lt;/span&gt;adduser &lt;span class="se"&gt;\
&lt;/span&gt;    &lt;span class="nt"&gt;--disabled-password&lt;/span&gt; &lt;span class="se"&gt;\
&lt;/span&gt;    &lt;span class="nt"&gt;--gecos&lt;/span&gt; &lt;span class="s2"&gt;""&lt;/span&gt; &lt;span class="se"&gt;\
&lt;/span&gt;    &lt;span class="nt"&gt;--home&lt;/span&gt; &lt;span class="s2"&gt;"/nonexistent"&lt;/span&gt; &lt;span class="se"&gt;\
&lt;/span&gt;    &lt;span class="nt"&gt;--shell&lt;/span&gt; &lt;span class="s2"&gt;"/sbin/nologin"&lt;/span&gt; &lt;span class="se"&gt;\
&lt;/span&gt;    &lt;span class="nt"&gt;--no-create-home&lt;/span&gt; &lt;span class="se"&gt;\
&lt;/span&gt;    &lt;span class="nt"&gt;--uid&lt;/span&gt; &lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="k"&gt;${&lt;/span&gt;&lt;span class="nv"&gt;UID&lt;/span&gt;&lt;span class="k"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt; &lt;span class="se"&gt;\
&lt;/span&gt;    appuser
&lt;span class="k"&gt;USER&lt;/span&gt;&lt;span class="s"&gt; appuser&lt;/span&gt;

&lt;span class="k"&gt;COPY&lt;/span&gt;&lt;span class="s"&gt; --from=extract build/target/extracted/dependencies/ ./&lt;/span&gt;
&lt;span class="k"&gt;COPY&lt;/span&gt;&lt;span class="s"&gt; --from=extract build/target/extracted/spring-boot-loader/ ./&lt;/span&gt;
&lt;span class="k"&gt;COPY&lt;/span&gt;&lt;span class="s"&gt; --from=extract build/target/extracted/snapshot-dependencies/ ./&lt;/span&gt;
&lt;span class="k"&gt;COPY&lt;/span&gt;&lt;span class="s"&gt; --from=extract build/target/extracted/application/ ./&lt;/span&gt;

&lt;span class="k"&gt;EXPOSE&lt;/span&gt;&lt;span class="s"&gt; 8080&lt;/span&gt;

&lt;span class="k"&gt;ENTRYPOINT&lt;/span&gt;&lt;span class="s"&gt; [ "java", "org.springframework.boot.loader.launch.JarLauncher" ]&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This is already a proper multi-stage build: separate stages for dependency resolution, compilation, layer extraction, and a minimal runtime image with a non-root user. Gord would approve.&lt;/p&gt;

&lt;h2&gt;
  
  
  A Note on Java 26 Base Images
&lt;/h2&gt;

&lt;p&gt;The generated Dockerfile references &lt;code&gt;eclipse-temurin:26-jdk-jammy&lt;/code&gt; and &lt;code&gt;eclipse-temurin:26-jre-jammy&lt;/code&gt;. Since Java 26 was just released, these Eclipse Temurin images may not be fully available on Docker Hub yet.&lt;/p&gt;

&lt;p&gt;Swap them out for SAP Machine images instead—SAP's free OpenJDK distribution ships Java 26 on Ubuntu 24.04 (Noble Numbat):&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;code&gt;sapmachine:26-jdk-ubuntu-noble&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;sapmachine:26-jre-ubuntu-noble&lt;/code&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Find them on Docker Hub: &lt;a href="https://hub.docker.com/_/sapmachine" rel="noopener noreferrer"&gt;hub.docker.com/_/sapmachine&lt;/a&gt;. Just replace &lt;code&gt;eclipse-temurin&lt;/code&gt; with &lt;code&gt;sapmachine&lt;/code&gt; in both &lt;code&gt;FROM&lt;/code&gt; lines.&lt;/p&gt;

&lt;h2&gt;
  
  
  Build and Run
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker compose up &lt;span class="nt"&gt;--build&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The generated &lt;code&gt;compose.yaml&lt;/code&gt; is minimal:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight yaml"&gt;&lt;code&gt;&lt;span class="na"&gt;services&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
  &lt;span class="na"&gt;server&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
    &lt;span class="na"&gt;build&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
      &lt;span class="na"&gt;context&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;.&lt;/span&gt;
    &lt;span class="na"&gt;ports&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
      &lt;span class="pi"&gt;-&lt;/span&gt; &lt;span class="s"&gt;8080:8080&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The application starts, and immediately stops with exit code 0. That's expected: there's no HTTP endpoint to keep it alive.&lt;/p&gt;

&lt;h2&gt;
  
  
  Add a Controller
&lt;/h2&gt;

&lt;p&gt;Create &lt;code&gt;src/main/java/io/dockersecurity/hellowowlrd/HelloController.java&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight java"&gt;&lt;code&gt;&lt;span class="kn"&gt;package&lt;/span&gt; &lt;span class="nn"&gt;io.dockersecurity.hellowowlrd&lt;/span&gt;&lt;span class="o"&gt;;&lt;/span&gt;

&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="nn"&gt;org.springframework.web.bind.annotation.GetMapping&lt;/span&gt;&lt;span class="o"&gt;;&lt;/span&gt;
&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="nn"&gt;org.springframework.web.bind.annotation.RestController&lt;/span&gt;&lt;span class="o"&gt;;&lt;/span&gt;

&lt;span class="nd"&gt;@RestController&lt;/span&gt;
&lt;span class="kd"&gt;public&lt;/span&gt; &lt;span class="kd"&gt;class&lt;/span&gt; &lt;span class="nc"&gt;HelloController&lt;/span&gt; &lt;span class="o"&gt;{&lt;/span&gt;

    &lt;span class="nd"&gt;@GetMapping&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"/"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="kd"&gt;public&lt;/span&gt; &lt;span class="nc"&gt;String&lt;/span&gt; &lt;span class="nf"&gt;hello&lt;/span&gt;&lt;span class="o"&gt;()&lt;/span&gt; &lt;span class="o"&gt;{&lt;/span&gt;
        &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="s"&gt;"Hello, Docker Security!"&lt;/span&gt;&lt;span class="o"&gt;;&lt;/span&gt;
    &lt;span class="o"&gt;}&lt;/span&gt;
&lt;span class="o"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Add the Spring Web dependency to &lt;code&gt;pom.xml&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight xml"&gt;&lt;code&gt;&lt;span class="nt"&gt;&amp;lt;dependency&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;groupId&amp;gt;&lt;/span&gt;org.springframework.boot&lt;span class="nt"&gt;&amp;lt;/groupId&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;artifactId&amp;gt;&lt;/span&gt;spring-boot-starter-web&lt;span class="nt"&gt;&amp;lt;/artifactId&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/dependency&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Build and run again:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker compose up &lt;span class="nt"&gt;--build&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Verify:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl http://localhost:8080
&lt;span class="c"&gt;# Hello, Docker Security!&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  See It Live — Jfokus 2026
&lt;/h2&gt;

&lt;p&gt;I presented Docker Init and Docker security at Jfokus in Stockholm in February 2026. If you want to see the commands in action rather than reading about them, the full talk is on YouTube:&lt;/p&gt;

&lt;p&gt;  &lt;iframe src="https://www.youtube.com/embed/_SXz9TSz93w"&gt;
  &lt;/iframe&gt;
&lt;/p&gt;

&lt;h2&gt;
  
  
  More Links
&lt;/h2&gt;

&lt;p&gt;Docker Init supports more than Java. If you want to try it with other languages, Docker's official guides are the place to start: &lt;a href="https://docs.docker.com/guides/" rel="noopener noreferrer"&gt;docs.docker.com/guides&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;I co-authored the C++ guide—Docker thanked me for it at the top of the page, which means I wrote those words and then thanked myself on their behalf. Worth a read:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://docs.docker.com/guides/cpp/" rel="noopener noreferrer"&gt;docs.docker.com/guides/cpp&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;Java 26 just shipped and Docker Init handles it cleanly out of the box—multi-stage build, layer extraction, non-root user, bind mounts for caching. You get a production-ready Dockerfile in under a minute. When Eclipse Temurin catches up, swap the base images back. Until then, SAP Machine has you covered.&lt;/p&gt;

&lt;p&gt;Docker Init is Gord's move. The rest of the Commandos handle what comes after.&lt;/p&gt;




&lt;h2&gt;
  
  
  The Docker Commandos
&lt;/h2&gt;

&lt;p&gt;Docker Init is assigned to &lt;strong&gt;Commando 1: Gord&lt;/strong&gt;. In the Docker Commandos workshop, each Docker security feature is taught through a character on a mission to defend Asgard from CVE monsters. The ten commandos are:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Gord&lt;/strong&gt; — &lt;code&gt;docker init&lt;/code&gt;: establish a secure base from day one ← &lt;em&gt;you are here&lt;/em&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Rothütle&lt;/strong&gt; — SBOM: inventory every dependency in your image&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Jack&lt;/strong&gt; — Docker Scout: hunt CVEs across your supply chain&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;The Valkyrie&lt;/strong&gt; — SBOM Attestations: cryptographically sign your component inventory&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Artemisia&lt;/strong&gt; — Docker Hardened Images: near-zero-CVE base images&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Mina&lt;/strong&gt; — VEX Exemptions: mark false-positive CVEs as not exploitable&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;RuinTan&lt;/strong&gt; — VEX Attestations: attach signed exemptions to your image&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Captain Ahab&lt;/strong&gt; — Docker Bake: codify your entire build pipeline in one file&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Evie&lt;/strong&gt; — Cosign: sign images and attestations cryptographically&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Agent Null&lt;/strong&gt; — Zero-Day Defense: harden against unknown, unpatched threats&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;The workshop has been delivered at WeAreDevelopers World Congress, Jfokus, and Rabobank. More at &lt;a href="https://dockersecurity.io/commandos" rel="noopener noreferrer"&gt;dockersecurity.io/commandos&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>docker</category>
      <category>java</category>
      <category>commandos</category>
    </item>
    <item>
      <title>The Complete Docker Read List: Q1 2026 Edition</title>
      <dc:creator>Mohammad-Ali A'RÂBI</dc:creator>
      <pubDate>Thu, 26 Mar 2026 17:21:39 +0000</pubDate>
      <link>https://forem.com/docker/the-complete-docker-read-list-q1-2026-edition-3gg8</link>
      <guid>https://forem.com/docker/the-complete-docker-read-list-q1-2026-edition-3gg8</guid>
      <description>&lt;p&gt;2026 has been phenomenal in the number of books published on Docker or by Docker Captains so far. So, I decided to compile the books published in the first quarter of 2026 into an article for more people to discover them.&lt;/p&gt;

&lt;p&gt;You can also read the article &lt;a href="https://www.dockersecurity.io/blog/docker-read-list-2026-q1" rel="noopener noreferrer"&gt;here&lt;/a&gt;, which looks slightly better.&lt;/p&gt;




&lt;h2&gt;
  
  
  1️⃣ Black Forest Shadow: A Dark Fantasy Guide to Docker and Kubernetes Security
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Author:&lt;/strong&gt; Mohammad-Ali A'râbi (Docker Captain)&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fby2euj9690nmf0ynp36d.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fby2euj9690nmf0ynp36d.jpg" alt="Black Forest Shadow book cover" width="680" height="1020"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;If you've ever thought learning about Kubernetes and container hardening was a bit dry, Mohammad-Ali A'râbi is here to prove you wrong. &lt;em&gt;Black Forest Shadow&lt;/em&gt; is a highly creative, dark fantasy guide to Docker and Kubernetes security.&lt;/p&gt;

&lt;p&gt;—Claude&lt;/p&gt;
&lt;/blockquote&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;What it's about:&lt;/strong&gt; The book weaves complex concepts like runtime security, SBOM generation, and container hardening into an exciting narrative set in the mystical Black Forest of 1865.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Why you should read it:&lt;/strong&gt; It transforms standard cybersecurity challenges—like tracking down CVEs and preventing lateral movement—into an immersive, story-driven adventure. It's ideal for developers and security engineers seeking a distinctive, memorable approach to DevSecOps.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Where to get it:&lt;/strong&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://buy.dockersecurity.io" rel="noopener noreferrer"&gt;DockerSecurity.io&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://DockerSecurity.io/amz/bfs" rel="noopener noreferrer"&gt;Amazon&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://www.thalia.de/shop/home/artikeldetails/A1078659350" rel="noopener noreferrer"&gt;Thalia&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://www.hugendubel.de/de/taschenbuch/mohammad_ali_a_rabi-black_forest_shadow-52778151-produkt-details.html" rel="noopener noreferrer"&gt;Hugendubel&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;/ul&gt;

&lt;h2&gt;
  
  
  2️⃣ The Rust Programming Handbook: An End-to-end Guide to Mastering Rust Fundamentals
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Author:&lt;/strong&gt; Francesco Ciulla (Docker Captain)&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F97qvqlgkns2cryqnax9x.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F97qvqlgkns2cryqnax9x.jpg" alt="The Rust Programming Handbook book cover" width="800" height="986"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Rust is the new C, and it's been on my list for 5 years now. Now, finally, I know which book to read to learn it. Written by my dear friend and fellow Docker Captain, Francesco Ciulla, who has been teaching Rust for many years now.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;What it's about:&lt;/strong&gt; This handbook takes you from foundational syntax to advanced features like memory safety and concurrency models. Crucially for this list, it includes dedicated, hands-on sections on Dockerizing and deploying your Rust applications!&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Why you should read it:&lt;/strong&gt; It bridges the gap between beginner tutorials and production-ready coding for low-level system components or high-performance web services.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Where to get it:&lt;/strong&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://www.packtpub.com/en-us/product/the-rust-programming-handbook-9781836208860" rel="noopener noreferrer"&gt;Packt Publishing&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://www.walmart.com/ip/The-Rust-Programming-Handbook-An-end-to-end-guide-to-mastering-Rust-fundamentals-Paperback-9781836208877/19000900376" rel="noopener noreferrer"&gt;Walmart&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;/ul&gt;

&lt;h2&gt;
  
  
  3️⃣ Docker for Front-end Developers (Featuring React.js)
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Author:&lt;/strong&gt; Kristiyan Velkov (Docker Captain)&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fcm2iyi46tzclgn1ejpk0.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fcm2iyi46tzclgn1ejpk0.jpg" alt="Docker for Front-end Developers book cover" width="640" height="837"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Front-end developers, rejoice! As a backend engineer, it has always been hard for me to onboard frontend people to Docker, because I spoke Klingon for them. My dear friend, Docker Captain Kristiyan Velkov, has done an awesome job writing a containerization guide specifically tailored to how front-end engineers think, build, and ship. I should say, it also looks good.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;What it's about:&lt;/strong&gt; Moving past backend-centric explanations, this book walks you through containerizing real-world applications (with a heavy focus on React). You'll learn how to write clean Dockerfiles, configure NGINX properly, implement multi-stage builds, and handle caching securely.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Why you should read it:&lt;/strong&gt; It's a purely practical, visually-driven guide that teaches you how to take full ownership of your environments without getting bogged down in abstract backend theory.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Where to get it:&lt;/strong&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://www.dockerfrontend.com/" rel="noopener noreferrer"&gt;Official website&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://leanpub.com/docker-reactjs" rel="noopener noreferrer"&gt;Leanpub&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://kristiyanvelkov.com/b/docker-for-reactjs-developers" rel="noopener noreferrer"&gt;Author's Website&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;/ul&gt;

&lt;h2&gt;
  
  
  4️⃣ The Ultimate Docker Container Book (Fourth Edition)
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Author:&lt;/strong&gt; Dr. Gabriel N. Schenker&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fyusiyhwdhrl4a7j5nvh5.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fyusiyhwdhrl4a7j5nvh5.jpg" alt="The Ultimate Docker Container Book cover" width="800" height="986"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Hitting shelves on March 31, 2026, this absolute heavyweight of a book clocks in at over 750 pages and leaves no stone unturned. Jeez, I need an extra bookshelf just for this book's weight.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;What it's about:&lt;/strong&gt; It takes you from basic container concepts all the way to running production-grade platforms. The fourth edition places a massive new emphasis on security, enterprise governance, compliance, and AI-driven automation patterns.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Why you should read it:&lt;/strong&gt; It is designed for system administrators, DevOps engineers, and architects who need to build and scale secure, future-ready container platforms across major cloud providers.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Where to get it:&lt;/strong&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://www.packtpub.com/en-be/product/the-ultimate-docker-container-book-9781805804390" rel="noopener noreferrer"&gt;Packt Publishing&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;/ul&gt;

&lt;h2&gt;
  
  
  5️⃣ Docker: Das Praxisbuch für Entwickler und DevOps-Teams (5th Edition)
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Authors:&lt;/strong&gt; Bernd Öggl &amp;amp; Michael Kofler&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F47a7f73aeecmkcfud9cl.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F47a7f73aeecmkcfud9cl.png" alt="Docker Das Praxisbuch book cover" width="565" height="800"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;For the German-speaking tech community, the definitive Docker reference guide gets a major Q1 2026 update.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;What it's about:&lt;/strong&gt; A comprehensive, 580+ page practical guide covering everything from setting up Docker to CI/CD pipelines, GitLab integration, Swarm, and Kubernetes orchestration.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Why you should read it:&lt;/strong&gt; It's an excellent, hands-on resource that balances basic principles with advanced, modern use cases like modernizing legacy applications and working with specialized databases.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Where to get it:&lt;/strong&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://www.rheinwerk-verlag.de/docker-das-praxisbuch-fuer-entwickler-und-devops-teams/" rel="noopener noreferrer"&gt;Rheinwerk Verlag&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;/ul&gt;

&lt;h2&gt;
  
  
  Honorable Mentions from 2025
&lt;/h2&gt;

&lt;p&gt;Well, while researching the new 2026 Docker books, I stumbled upon a recent video by Bret Fisher interviewing the author of a rather interesting book. That inspired me to add this honorable mentions section. I promise my original intention wasn't to sneak my own book in here, but hey, it just happened!&lt;/p&gt;

&lt;h3&gt;
  
  
  Learn Docker in a Month of Lunches (Second Edition)
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Author:&lt;/strong&gt; Elton Stoneman&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fytaopwmeln2pbmceqpfr.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fytaopwmeln2pbmceqpfr.png" alt="Learn Docker in a Month of Lunches book cover" width="360" height="451"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Published in 2025, this is the much-anticipated update to one of the most beloved Docker books on the market.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;What it's about:&lt;/strong&gt; A complete refresh of the classic guide. It breaks down Docker fundamentals into digestible, daily lessons. This edition covers multi-platform builds, the latest cloud container services, and navigating the modern Kubernetes ecosystem.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Why you should read it:&lt;/strong&gt; If you are a beginner looking for a structured, manageable way to learn—or an experienced dev needing to catch up on years of ecosystem changes—this is the gold standard.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Where to get it:&lt;/strong&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://www.manning.com/" rel="noopener noreferrer"&gt;Manning Publications&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;/ul&gt;

&lt;h3&gt;
  
  
  Getting Started with Docker (2025 Edition)
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Author:&lt;/strong&gt; Nigel Poulton (Docker Captain)&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7upkb6g6wxq9uxd6ucyj.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7upkb6g6wxq9uxd6ucyj.jpg" alt="Getting Started with Docker book cover" width="640" height="831"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Nigel Poulton's fast-paced introduction to Docker received a significant 2025 update, adding a dedicated chapter on running local LLMs with Docker Model Runner — including building a multi-container chatbot app.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;What it's about:&lt;/strong&gt; A streamlined, hands-on guide to container fundamentals, Docker Compose, and microservices — now with a practical AI chapter for developers who want to run models locally.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Why you should read it:&lt;/strong&gt; It's the quickest path from zero to productive with Docker, and the new AI content makes it uniquely relevant for 2025 and beyond.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Where to get it:&lt;/strong&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://leanpub.com/gsd" rel="noopener noreferrer"&gt;Leanpub&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;/ul&gt;

&lt;h3&gt;
  
  
  Docker and Kubernetes Security
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Author:&lt;/strong&gt; Mohammad-Ali A'râbi (Docker Captain)&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fa5p1waauyl3hgera887u.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fa5p1waauyl3hgera887u.jpg" alt="Docker and Kubernetes Security book cover" width="640" height="793"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A DevOps Dozen 2025 finalist for Best DevOps Book of the Year, this practical guide covers container security across the full development lifecycle—from build to production.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;What it's about:&lt;/strong&gt; Ten chapters spanning supply chain security (SBOMs, OCI 1.1 attestations, vulnerability scanning with Docker Scout, Trivy, and Snyk) and runtime protection with Falco, RBAC, and Kubernetes pod security.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Why you should read it:&lt;/strong&gt; It is the most comprehensive hands-on resource available for teams serious about securing their container platforms end-to-end.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Where to get it:&lt;/strong&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://buy.dockersecurity.io" rel="noopener noreferrer"&gt;DockerSecurity.io&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://buy.dockersecurity.io/amz/dks" rel="noopener noreferrer"&gt;Amazon&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;/ul&gt;

&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;The Docker and Kubernetes ecosystem has never had a stronger reading list, to be &lt;em&gt;completely&lt;/em&gt; humble! From dark fantasy security guides to hands-on Rust handbooks and front-end containerization primers, Q1 2026 proves that the community is producing more creative, accessible, and production-focused material than ever before.&lt;/p&gt;

&lt;p&gt;Stay tuned as more books are coming in Q2. I'm involved in reviewing one of them, so I'm excited for the quarter to come.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Have a book that should be on this list? Leave a comment.&lt;/em&gt;&lt;/p&gt;

</description>
      <category>docker</category>
      <category>books</category>
    </item>
    <item>
      <title>Docker Just Made Hardened Images Free for Everyone – Let's Check Them Out!</title>
      <dc:creator>Anil Kumar Moka</dc:creator>
      <pubDate>Mon, 29 Dec 2025 02:03:18 +0000</pubDate>
      <link>https://forem.com/docker/docker-just-made-hardened-images-free-for-everyone-lets-check-them-out-499h</link>
      <guid>https://forem.com/docker/docker-just-made-hardened-images-free-for-everyone-lets-check-them-out-499h</guid>
      <description>&lt;p&gt;Hey everyone! If you're like me and spend a lot of time building and deploying containers, you've probably worried about security at some point. Supply chain attacks are no joke these days, and starting with a solid, secure base can make a huge difference. That's why I'm super excited about the recent news from Docker: they've made Docker Hardened Images (DHI) completely free and open source for all developers!Back in May 2025, Docker launched these hardened images as a way to give us minimal, secure, production-ready bases. And just a couple weeks ago (December 17, 2025), they announced that the whole catalog – over 1,000 images and Helm charts – is now free, under Apache 2.0. No subscriptions needed for the basics, no restrictions, no gotchas. This feels like a game-changer for making secure containers the default instead of an afterthought.Let me break it down for you based on the official blog post and docs, and share some practical ways you can start using them today.&lt;/p&gt;

&lt;h2&gt;
  
  
  What Are Docker Hardened Images?
&lt;/h2&gt;

&lt;p&gt;In simple terms, DHI are container images that Docker maintains with security front and center. They're built on familiar bases like Alpine and Debian, but stripped down to the essentials. No unnecessary shells, compilers, or package managers that could open up attack vectors.The result? &lt;br&gt;
Images up to 95% smaller&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Way fewer CVEs (they aim for near-zero)&lt;/li&gt;
&lt;li&gt;Secure defaults, like running as non-root&lt;/li&gt;
&lt;li&gt;Full transparency with SBOMs (software bill of materials), &lt;/li&gt;
&lt;li&gt;SLSA Level 3 provenance, and no hidden vulnerabilities&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;They're inspired by distroless ideas but keep enough tools so you don't have to fight with them in real workflows. And unlike some proprietary options, these are open, compatible with what you're already using, and easy to adopt.&lt;/p&gt;

&lt;p&gt;There's a free tier for everyone, and an Enterprise version if you need extras like FIPS compliance, customizations, or super-fast patching SLAs.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why This Matters (And Why Now)
&lt;/h2&gt;

&lt;p&gt;Supply chain attacks are exploding – projected to cost $60 billion this year alone. A lot of that risk comes from bloated base images pulling in stuff your app doesn't need. By starting with a hardened image, you're shrinking that attack surface right from the first docker build.Docker's basically saying: let's make secure-by-default the new normal. And with partnerships from folks like Google, MongoDB, and CNCF, plus companies like Adobe and Qualcomm already using them, it seems like it's catching on fast.&lt;/p&gt;

&lt;h2&gt;
  
  
  How to Get Started – It's Super Easy
&lt;/h2&gt;

&lt;p&gt;Head over to the catalog on Docker Hub: &lt;a href="https://hub.docker.com/hardened-images/catalog" rel="noopener noreferrer"&gt;https://hub.docker.com/hardened-images/catalog&lt;/a&gt; (you might need to sign in with your Docker ID).Or pull directly from dhi.io. &lt;/p&gt;

&lt;p&gt;For example, let's try a Python one:bash&lt;/p&gt;

&lt;p&gt;&lt;code&gt;docker pull dhi.io/python:3.13&lt;br&gt;
&lt;/code&gt;&lt;br&gt;
Then run something simple:bash&lt;/p&gt;

&lt;p&gt;&lt;code&gt;docker run --rm dhi.io/python:3.13 python -c "print('Hello from a hardened image!')"&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;In your Dockerfile, just swap the base:&lt;/p&gt;

&lt;p&gt;&lt;code&gt;FROM dhi.io/python:3.13&lt;br&gt;
COPY . /app&lt;br&gt;
WORKDIR /app&lt;br&gt;
CMD ["python", "app.py"]&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;They work great in CI/CD too. And if you're on Kubernetes, check out the open source Hardened Helm Charts.&lt;br&gt;
Pro tip from the docs: These images are minimal on purpose, so no shell by default in runtime variants. Use multi-stage builds – compile in a -dev or -sdk tag, then copy to the slim runtime one.&lt;/p&gt;

&lt;h2&gt;
  
  
  Some Practical Use Cases I Can See
&lt;/h2&gt;

&lt;p&gt;Imagine you're building a Node.js API for a startup. Instead of starting with the regular node image (which has extra stuff), switch to a hardened one. Smaller images mean faster deploys, fewer vulnerabilities to scan, and you sleep better knowing it's locked down.&lt;/p&gt;

&lt;p&gt;Or say you're deploying MongoDB in prod. Docker has hardened versions of popular MCP servers like Mongo, Grafana, and more. Drop one in, and you've got a secure foundation without rolling your own hardening scripts.&lt;/p&gt;

&lt;p&gt;For teams in regulated spaces (finance, healthcare), the free versions already give huge wins on CVEs and size. Upgrade to Enterprise if you need FIPS or extended support after upstream EOL.Even for personal projects or learning, why not start secure? It costs nothing extra now.&lt;/p&gt;

&lt;p&gt;This move by Docker feels huge, putting hardened, transparent images in everyone's hands for free. If you've been putting off tightening up your container security, now's the perfect time to jump in. Go browse the catalog, pull a couple images, and see the difference yourself. Planning to switch any of your projects over? Drop a comment if you've tried them already!&lt;/p&gt;

</description>
      <category>docker</category>
      <category>security</category>
      <category>devops</category>
      <category>opensource</category>
    </item>
    <item>
      <title>Docker Hardened Images are Free</title>
      <dc:creator>Mohammad-Ali A'RÂBI</dc:creator>
      <pubDate>Wed, 17 Dec 2025 14:17:35 +0000</pubDate>
      <link>https://forem.com/docker/docker-hardened-images-are-free-3cj1</link>
      <guid>https://forem.com/docker/docker-hardened-images-are-free-3cj1</guid>
      <description>&lt;p&gt;Docker introduced &lt;strong&gt;Hardened Images&lt;/strong&gt; in 2025 as a &lt;strong&gt;secure-by-default base image line&lt;/strong&gt;, designed to keep production and development images as close to &lt;strong&gt;zero known CVEs&lt;/strong&gt; as realistically possible.&lt;/p&gt;

&lt;p&gt;As supply chain attacks are on the rise, Docker made the Hardened Images open-source under the Apache 2.0 license to let the community audit and contribute to them.&lt;/p&gt;

&lt;p&gt;From now on, you can use the hardened images for free in your projects:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight docker"&gt;&lt;code&gt;&lt;span class="c"&gt;# For build stage&lt;/span&gt;
&lt;span class="k"&gt;FROM&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;dhi.io/node:24-dev&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;AS&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;build&lt;/span&gt;

&lt;span class="c"&gt;# For production stage&lt;/span&gt;
&lt;span class="k"&gt;FROM&lt;/span&gt;&lt;span class="s"&gt; dhi.io/node:24&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;To get started, visit &lt;a href="https://dhi.io" rel="noopener noreferrer"&gt;dhi.io&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  How to Pull Hardened Images Locally
&lt;/h2&gt;

&lt;p&gt;To pull the images locally, you need to log into &lt;code&gt;dhi.io&lt;/code&gt; first:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker login dhi.io
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The images are free to use, but you still need to authenticate before pulling them.&lt;/p&gt;

&lt;p&gt;Use your Docker Hub credentials to login. You can use your personal Docker Hub account and a personal access token (PAT) as the password. No special subscription is required.&lt;/p&gt;

&lt;p&gt;Then pull the desired image:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker pull dhi.io/node:24
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Check for CVEs
&lt;/h2&gt;

&lt;p&gt;To check for CVEs in the images, you can use Docker Scout:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker scout cves dhi.io/node:24
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The image has 8 low-severity CVEs as of December 17th, 2025, as there are no fixed versions available for those packages:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;8 vulnerabilities found in 2 packages
  CRITICAL  0  
  HIGH      0  
  MEDIUM    0  
  LOW       8
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;To check with Trivy:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;trivy image &lt;span class="nt"&gt;--scanners&lt;/span&gt; vuln dhi.io/node:24
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Trivy also found 7 low-severity CVEs on one package:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;dhi.io/node:24 (debian 13.2)

Total: 7 (UNKNOWN: 0, LOW: 7, MEDIUM: 0, HIGH: 0, CRITICAL: 0)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You can still use the Alpine-based hardened images to have a smaller attack surface.&lt;/p&gt;

&lt;h2&gt;
  
  
  Final Words
&lt;/h2&gt;

&lt;p&gt;There are more than 500 different tags just for the Node.js Hardened Images available on &lt;code&gt;dhi.io&lt;/code&gt;, including Alpine-based, Debian-based, dev and runtime, and FIPS and STIG-compliant images. And there are some 100 different repositories for other languages and runtimes, such as Python, Go, Java, .NET, Ruby, and more. And there are Helm charts to deploy DHI images on Kubernetes clusters directly.&lt;/p&gt;

&lt;p&gt;To explore all available images, visit the &lt;a href="https://dhi.io" rel="noopener noreferrer"&gt;DHI Catalog&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;To learn more about Docker and Kubernetes security, check out my book &lt;a href="https://buy.dockersecurity.io" rel="noopener noreferrer"&gt;Docker and Kubernetes Security&lt;/a&gt;, currently 40% off with code &lt;strong&gt;BLACKFOREST25&lt;/strong&gt;.&lt;/p&gt;

</description>
      <category>docker</category>
      <category>kubernetes</category>
      <category>security</category>
    </item>
    <item>
      <title>I Just Published My Book: Docker and Kubernetes Security</title>
      <dc:creator>Mohammad-Ali A'RÂBI</dc:creator>
      <pubDate>Tue, 21 Oct 2025 12:26:34 +0000</pubDate>
      <link>https://forem.com/docker/i-just-published-my-book-docker-and-kubernetes-security-17lo</link>
      <guid>https://forem.com/docker/i-just-published-my-book-docker-and-kubernetes-security-17lo</guid>
      <description>&lt;p&gt;The book &lt;em&gt;Docker and Kubernetes Security&lt;/em&gt; is finally here, after two years, 170 git commits, and countless hours of writing, editing, and reviewing. It's available on &lt;a href="https://DockerSecurity.io" rel="noopener noreferrer"&gt;DockerSecurity.io&lt;/a&gt;. You can get the eBook, paperback, or a signed copy (that I'll sign and send to you). 🐳🔐&lt;/p&gt;

&lt;p&gt;So, why did I write this book?&lt;/p&gt;

&lt;h2&gt;
  
  
  An Unexpected Journey
&lt;/h2&gt;

&lt;p&gt;I became a Docker Captain in March 2023. That probably put me on this publisher's radar. Shortly after that, a major UK publisher reached out to me, asking if I would be interested in writing a book on Docker Security. At first, I was hesitant. Writing a book is a huge commitment, and I wasn't sure if I had enough expertise in Docker Security. The publisher was very persuasive, though, and I eventually agreed to write a proposal.&lt;/p&gt;

&lt;p&gt;Here is my &lt;a href="https://x.com/MohammadAliEN/status/1676867268414676994" rel="noopener noreferrer"&gt;monthly tweet&lt;/a&gt; about writing a proposal in July 2023:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;July 2023 goals:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;👾 Practice C with Exercism&lt;/li&gt;
&lt;li&gt;🐳 Submit a Docker talk&lt;/li&gt;
&lt;li&gt;📝 Write a piece on Telepresence&lt;/li&gt;
&lt;li&gt;🚘 Pass the driving theory exam&lt;/li&gt;
&lt;li&gt;📚 Finish the book proposal&lt;/li&gt;
&lt;/ul&gt;
&lt;/blockquote&gt;

&lt;p&gt;Well, I never made it to that DockerCon, because my visa is still pending. But I did finish the proposal!&lt;/p&gt;

&lt;p&gt;I finished the book, it went through multiple rounds of editing and reviewing, and the technical reviewers gave me a green light by the end of 2024. I was waiting for the final copy-editing and typesetting to be done when I got an email from the publisher in February 2025, named "Intro Call". There was some reorganization happening at the publisher, and they assigned a new team to my book. The intro call was super nice and happy. Then I got an email in March 2025, saying that they are canceling the book project "after a thorough review". I said, "Sure, just verify that the rights are reverted to me". They wrote:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Yes, the manuscripts belong to you, and you can find an alternative publisher.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;I thought, "I have found a new publisher, and that's me!"&lt;/p&gt;

&lt;h2&gt;
  
  
  Self-Publishing
&lt;/h2&gt;

&lt;p&gt;I set a deadline for myself: October 1st, 2025. I personally love October. It's the month of Oktoberfest, Hacktoberfest, and Halloween. And people are back from Summer mood.&lt;/p&gt;

&lt;p&gt;When I &lt;a href="https://www.linkedin.com/posts/aerabi_docker-kubernetes-activity-7308072260005720065-xSkU?utm_source=share&amp;amp;utm_medium=member_desktop&amp;amp;rcm=ACoAAA4-2tsBY5vUuUj8Cp2-8SacUv_cLm1lUmo" rel="noopener noreferrer"&gt;posted on LinkedIn that's publishing in October&lt;/a&gt;, I received overwhelming support and encouragement from my network. The post received 5,000 views, 75 reactions, and 20 comments of encouragement.&lt;/p&gt;

&lt;p&gt;So, I started reaching out to my network for help with self-publishing. Docker Captain Vladimir Mikhalev accepted to be my technical editor. Other Docker Captains accepted to read beta copies and give feedback. I typeset the book using Markdown and LaTeX, and my friend Sima Maherani designed a beautiful cover for it.&lt;/p&gt;

&lt;p&gt;I started using Amazon's Kindle Direct Publishing (KDP) to publish the eBook and paperback versions. I also set up a website, &lt;a href="https://DockerSecurity.io" rel="noopener noreferrer"&gt;DockerSecurity.io&lt;/a&gt;, to sell signed copies and provide additional resources.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ftwqffc2xxdyrxlld512o.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ftwqffc2xxdyrxlld512o.jpg" alt="Francesco Ciulla and I in Berlin" width="800" height="1066"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;I took two copies of the book to my talk at WeAreDevelopers in Berlin, where I ran a workshop on Docker Security. There, I ran into Docker Captain Francesco Ciulla, who said he would promote the book when it comes out. I also met Liran Tal, Director of Developer Advocacy at Snyk, who later wrote a foreword for the book.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F173zpv83k9hdwejhkx2u.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F173zpv83k9hdwejhkx2u.jpg" alt="Liran Tal and I in Berlin" width="800" height="600"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  The Launch
&lt;/h2&gt;

&lt;p&gt;Finally, the big day arrived: October 1st, 2025. The book was launched on Amazon and &lt;a href="https://DockerSecurity.io" rel="noopener noreferrer"&gt;DockerSecurity.io&lt;/a&gt;. Amazon's KDP network mostly supported English-speaking countries, plus some European countries. Many other countries were not supported, for example, India, although Amazon has a big presence there. So, I set up a signed copy option on &lt;a href="https://buy.DockerSecurity.io" rel="noopener noreferrer"&gt;buy.DockerSecurity.io&lt;/a&gt; to ship books worldwide.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fs89l2lh5k0jwr0gbkjfr.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fs89l2lh5k0jwr0gbkjfr.jpeg" alt="Launch meetup" width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Again, after the launch, I received overwhelming support from my network. People started purchasing the book and leaving reviews on Amazon and Goodreads. Docker reshared my launch post on their official LinkedIn page, as well as on Twitter.&lt;/p&gt;

&lt;p&gt;An Indian Docker Captain reached out and said he wants to give away copies of the book to the winners of a Hackathon he was organizing. It was a challenge to get him the book in time, but we managed to do it. More Captains reached out to congratulate me and offer help with promotion.&lt;/p&gt;

&lt;p&gt;So far, 3 weeks after the launch, we have had a slow start, but the momentum is building up. The book had sales in Japan, although I did not promote it there. Sales are mostly in Germany, where I'm based. I have received requests from readers in Iran and India who wanted to buy the book but could not find a way to do it. The signed copy is an option, but still expensive, as it's printed in Europe and shipped internationally.&lt;/p&gt;

&lt;p&gt;I'm currently working with an Indian printer to make the book available in Asia, Africa, and the Middle East. I'm also registering my own ISBN to make the book available in bookstores. They would usually refuse to stock books with Amazon's ISBN.&lt;/p&gt;

&lt;p&gt;If you are interested in ordering the book, you can find it here: &lt;a href="https://buy.DockerSecurity.io" rel="noopener noreferrer"&gt;buy.DockerSecurity.io&lt;/a&gt;. You can use the following code for a 10 Euros discount: &lt;strong&gt;DEVTO&lt;/strong&gt; 🏷️&lt;/p&gt;

&lt;p&gt;If you want to order on Amazon, you can find the links here: &lt;a href="https://DockerSecurity.io" rel="noopener noreferrer"&gt;DockerSecurity.io&lt;/a&gt;. The website will redirect you to the appropriate Amazon store based on your location.&lt;/p&gt;

&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;Writing and self-publishing a technical book is a challenging but rewarding experience. It requires a lot of dedication, perseverance, and support from your network. I'm grateful for everyone who helped me along the way, and I'm excited to see where this journey takes me next.&lt;/p&gt;

&lt;p&gt;If you want to write a book, you can reach out to me, and I can share the code base I built with Pandoc and LaTeX to help you get started.&lt;/p&gt;

&lt;p&gt;Meet the heroes who made &lt;em&gt;Docker and Kubernetes Security&lt;/em&gt; possible:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fs8brzb39b98tsgmm4bz0.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fs8brzb39b98tsgmm4bz0.jpg" alt="The book's back cover: Choose your Fighter" width="800" height="987"&gt;&lt;/a&gt;&lt;/p&gt;

</description>
      <category>docker</category>
      <category>books</category>
      <category>programming</category>
      <category>writing</category>
    </item>
    <item>
      <title>MCP Horror Stories - Issue 1</title>
      <dc:creator>Ajeet Singh Raina</dc:creator>
      <pubDate>Fri, 01 Aug 2025 15:23:10 +0000</pubDate>
      <link>https://forem.com/docker/mcp-horror-stories-issue-1-2mki</link>
      <guid>https://forem.com/docker/mcp-horror-stories-issue-1-2mki</guid>
      <description>&lt;p&gt;The Model Context Protocol (MCP) is a standardized interface that enables AI agents to interact with external tools, databases, and services. Launched by Anthropic in November 2024, MCP has achieved remarkable adoption, with thousands of MCP server repositories emerging on GitHub. Major technology giants, including Microsoft, OpenAI, Google, and Amazon, have officially integrated MCP support into their platforms, with development tools companies like Block, Replit, Sourcegraph, and Zed also adopting the protocol. &lt;/p&gt;

&lt;p&gt;Think of MCP as the plumbing that allows ChatGPT, Claude, or any AI agent to read your emails, update databases, manage files, or interact with APIs. Instead of building custom integrations for every tool, developers can use one protocol to connect everything. &lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fat0dermp1mpbkaybk86m.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fat0dermp1mpbkaybk86m.png" alt="Image1" width="800" height="907"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The Model Context Protocol (MCP) was supposed to be the “USB-C for AI applications” – a universal standard that would let AI agents safely connect to any tool or service. Instead, it’s become a security nightmare that’s putting organizations at risk of data breaches, system compromises, and supply chain attacks.&lt;/p&gt;

&lt;p&gt;The promise is compelling: Write once, connect everywhere. The reality is terrifying: A protocol designed for convenience, not security.&lt;/p&gt;

&lt;p&gt;This is issue 1 of a new series – MCP Horror Stories – where we will examine critical security issues and vulnerabilities in the Model Context Protocol (MCP) ecosystem and how Docker MCP Toolkit provides enterprise-grade protection against these threats.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://www.docker.com/blog/mcp-security-issues-threatening-ai-infrastructure/" rel="noopener noreferrer"&gt;Click here to Read the complete blog&lt;/a&gt;&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Docker Deep Dive Workshop at WeAreDevelopers</title>
      <dc:creator>Mohammad-Ali A'RÂBI</dc:creator>
      <pubDate>Wed, 09 Jul 2025 22:30:48 +0000</pubDate>
      <link>https://forem.com/docker/docker-deep-dive-workshop-at-wearedevelopers-110c</link>
      <guid>https://forem.com/docker/docker-deep-dive-workshop-at-wearedevelopers-110c</guid>
      <description>&lt;p&gt;Today, I conducted a workshop at WeAreDevelopers World Congress 2025 titled:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;a href="https://app.wearedevelopers.com/events/14/session/35" rel="noopener noreferrer"&gt;Docker Deep Dive with a Docker Captain&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;The workshop covered the following topics:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Docker Init&lt;/li&gt;
&lt;li&gt;Docker Bake&lt;/li&gt;
&lt;li&gt;Docker SBOM&lt;/li&gt;
&lt;li&gt;SBOM attestations&lt;/li&gt;
&lt;li&gt;Docker Scout&lt;/li&gt;
&lt;li&gt;Docker Debug&lt;/li&gt;
&lt;li&gt;Docker Model Runner&lt;/li&gt;
&lt;li&gt;Ask Gordon&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This article is a step-by-step guide that walks you through the topics, allowing you to recreate the workshop for yourself on demand.&lt;/p&gt;

&lt;h2&gt;
  
  
  Links
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;The GitHub repo: &lt;a href="https://github.com/DockerSecurity-io/wap" rel="noopener noreferrer"&gt;github.com/DockerSecurity-io/wap&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;&lt;a href="https://DockerSecurity.io/" rel="noopener noreferrer"&gt;Docker and Kubernetes Security Book&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Technical Requirements
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Docker Desktop latest version&lt;/li&gt;
&lt;li&gt;Git&lt;/li&gt;
&lt;li&gt;A Bash shell (e.g., Git Bash, WSL, or any Linux terminal)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;On Windows, you can install Git Bash.&lt;/p&gt;

&lt;h2&gt;
  
  
  1. Docker Init
&lt;/h2&gt;

&lt;p&gt;&lt;em&gt;Main article: &lt;a href="https://dockerhour.com/dockerizing-a-java-24-project-with-docker-init-6f6465758c55" rel="noopener noreferrer"&gt;Dockerizing a Java 24 Project with Docker Init&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Main article: &lt;a href="https://javapro.io/2025/07/03/how-to-containerize-a-java-application-securely/" rel="noopener noreferrer"&gt;JAVAPRO: How to Containerize a Java Application Securely&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Docker Init is a command to initialize a Docker project with a Dockerfile and other necessary files:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;code&gt;Dockerfile&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;compose.yaml&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;.dockerignore&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;README.Docker.md&lt;/code&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The command doesn't use GenAI, so is deterministic, and employs best practices for Dockerfile creation.&lt;/p&gt;

&lt;p&gt;Docker Init is available on Docker Desktop 4.27 or later and is generally available.&lt;/p&gt;

&lt;h3&gt;
  
  
  Usage
&lt;/h3&gt;

&lt;p&gt;On the repo, go to the Flask example directory:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;cd &lt;/span&gt;flask
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then, run the Docker Init command:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker init
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The command will ask you 4 questions, accept the defaults:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;? What application platform does your project use? &lt;strong&gt;Python&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;? What version of Python do you want to use? &lt;strong&gt;3.13.2&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;? What port do you want your app to listen on? &lt;strong&gt;8000&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;? What is the command you use to run your app? &lt;strong&gt;gunicorn 'hello:app' --bind=0.0.0.0:8000&lt;/strong&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Then, start Docker Compose with build:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker compose up &lt;span class="nt"&gt;--build&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The application will be available at &lt;a href="http://localhost:8000" rel="noopener noreferrer"&gt;http://localhost:8000&lt;/a&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  Exercises
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;1.1. If you want a more tricky example, try Dockerizing a Java 24 application using Docker Init. You can follow the instructions in the &lt;a href="https://javapro.io/2025/07/03/how-to-containerize-a-java-application-securely/" rel="noopener noreferrer"&gt;JAVAPRO article&lt;/a&gt; that I published last week.&lt;/li&gt;
&lt;li&gt;1.2. Compare the Dockerfile created for the Java application with the one created for the Python application. What are the differences?&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  2. Docker Bake
&lt;/h2&gt;

&lt;p&gt;&lt;em&gt;Requirement: This step requires the Docker Init step to be completed first.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Docker Bake is to Docker Build, what Docker Compose is to Docker Run. It allows you to build multiple images at once, using a single command.&lt;/p&gt;

&lt;p&gt;Docker Bake is available on Docker CE and Docker Desktop, and is generally available.&lt;/p&gt;

&lt;h3&gt;
  
  
  Usage
&lt;/h3&gt;

&lt;p&gt;In the repo, go to the Flask example directory:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;cd &lt;/span&gt;flask
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then, try to build the image using Docker Bake:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker buildx bake
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The command will build the image using the &lt;code&gt;docker-bake.hcl&lt;/code&gt; file in the current directory. At the end, there is a Docker Desktop link shown in the output, with which you can see the build progress in the Docker Desktop UI.&lt;/p&gt;

&lt;p&gt;Also, there are probably some warnings about the Dockerfile.&lt;/p&gt;

&lt;h3&gt;
  
  
  Exercises
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;2.1. Try to fix the warnings in the Dockerfile.&lt;/li&gt;
&lt;li&gt;2.2. By changing the &lt;code&gt;docker-bake.hcl&lt;/code&gt; file, try building for multiple platforms, e.g., &lt;code&gt;linux/amd64&lt;/code&gt; and &lt;code&gt;linux/arm64&lt;/code&gt;. &lt;/li&gt;
&lt;li&gt;2.3. Try to build the image with a different Python version, e.g., &lt;code&gt;3.13.1&lt;/code&gt; (the Python version is defined in the Dockerfile as a build argument, &lt;code&gt;PYTHON_VERSION&lt;/code&gt;).&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  3. Docker SBOM
&lt;/h2&gt;

&lt;p&gt;&lt;em&gt;Requirement: This step requires the Docker Init step to be completed first.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;In Docker Init step, we built an image with tag &lt;code&gt;flask-server:latest&lt;/code&gt; when running &lt;code&gt;docker compose up --build&lt;/code&gt;. Let's check the SBOM for this image.&lt;/p&gt;

&lt;p&gt;Docker SBOM is integrated into Docker Desktop, but is also available for Docker CE as a CLI plugin that you need to install separately.&lt;/p&gt;

&lt;h3&gt;
  
  
  Usage
&lt;/h3&gt;

&lt;p&gt;To check the SBOM for the image, run:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker sbom flask-server:latest
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The output will show the SBOM in a table format. Try to export it to a SPDX file:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker sbom &lt;span class="nt"&gt;--format&lt;/span&gt; spdx-json flask-server:latest &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; sbom.spdx.json
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;If you investigate the file, you will see that it contains a list of all the packages used in the image, their versions, and the licenses. It's especially useful for compliance and security purposes.&lt;/p&gt;

&lt;p&gt;A more interesting example will be a C++ application.&lt;/p&gt;

&lt;p&gt;Go to the C++ example directory:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;cd &lt;/span&gt;cpp
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then, build the image:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker build &lt;span class="nt"&gt;-t&lt;/span&gt; cpp-hello &lt;span class="nb"&gt;.&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now, check the SBOM for the image:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker sbom cpp-hello
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It will say there are no packages in the image, because the image is built from a &lt;code&gt;FROM scratch&lt;/code&gt; base image. But, in the build stage, we installed many packages, and a vulnerability in those packages can affect the final image.&lt;/p&gt;

&lt;p&gt;We'll get back to this later.&lt;/p&gt;

&lt;h3&gt;
  
  
  Exercises
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;3.1. Try to create a Docker Bake file for the C++ example, and build the image using Docker Bake.&lt;/li&gt;
&lt;li&gt;3.2. Use &lt;code&gt;docker sbom --help&lt;/code&gt; to check available formats for the SBOM output.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  4. SBOM Attestations
&lt;/h2&gt;

&lt;p&gt;&lt;em&gt;Requirement: This step requires the Docker SBOM step to be completed first.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Main article: &lt;a href="https://docs.docker.com/guides/cpp/security/" rel="noopener noreferrer"&gt;DockerDocs: Supply-Chain Security for C++ Images&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;SBOM attestations are SBOMs generated for Docker images and uploaded with them to the registry.&lt;/p&gt;

&lt;h3&gt;
  
  
  Usage
&lt;/h3&gt;

&lt;p&gt;SBOM attestations are generated during the build and pushed to the registry automatically:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker buildx build &lt;span class="nt"&gt;--sbom&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nb"&gt;true&lt;/span&gt; &lt;span class="nt"&gt;--push&lt;/span&gt; &lt;span class="nt"&gt;-t&lt;/span&gt; aerabi/cpp-hello &lt;span class="nb"&gt;.&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now, let's check the CVEs with Docker Scout (we will cover it in the next section):&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker scout cves aerabi/cpp-hello
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It will say:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;SBOM obtained from attestation, 0 packages found
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The SBOM has no packages, because we built the image from a &lt;code&gt;FROM scratch&lt;/code&gt; base image, and the build stage packages are not included in the SBOM. We can fix this by including the build stage packages in the SBOM.&lt;/p&gt;

&lt;p&gt;To do that, we need to add the following line to the beginning of the &lt;code&gt;Dockerfile&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight docker"&gt;&lt;code&gt;&lt;span class="k"&gt;ARG&lt;/span&gt;&lt;span class="s"&gt; BUILDKIT_SBOM_SCAN_STAGE=true&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This line goes before the &lt;code&gt;FROM&lt;/code&gt; line, and it tells Docker to include the build stage packages in the SBOM.&lt;/p&gt;

&lt;p&gt;Now, rebuild the image with the new Dockerfile:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker buildx build &lt;span class="nt"&gt;--sbom&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nb"&gt;true&lt;/span&gt; &lt;span class="nt"&gt;--push&lt;/span&gt; &lt;span class="nt"&gt;-t&lt;/span&gt; aerabi/cpp-hello:with-build-stage &lt;span class="nb"&gt;.&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now, check the SBOM attestations for the image again:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker scout cves aerabi/cpp-hello:with-build-stage
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It will say:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;SBOM of image already cached, 208 packages indexed
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Exercises
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;4.1. Here, the build command was super long. Try to create a Docker Bake file for the C++ example, and build the image using Docker Bake with SBOM attestations.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  5. Docker Scout
&lt;/h2&gt;

&lt;p&gt;&lt;em&gt;Requirement: This step requires the SBOM Attestations step to be completed first.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Docker Scout is a tool to analyze Docker images and check for vulnerabilities, misconfigurations, and other issues. It uses the SBOM attestations, when available, to provide more accurate results.&lt;/p&gt;

&lt;p&gt;Docker Scout is available on Docker Desktop, and as a CLI plugin for Docker CE.&lt;/p&gt;

&lt;h3&gt;
  
  
  Usage
&lt;/h3&gt;

&lt;p&gt;To check the vulnerabilities in the image, run:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker scout cves aerabi/cpp-hello:with-build-stage
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You can also check the vulnerabilities in the image using the Docker Desktop UI. Just go to the "Images" tab, select the image, and click on "Scout".&lt;/p&gt;

&lt;p&gt;There are also recommendations for the image, which you can check by running:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker scout recommendations flask-server
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Exercises
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;5.1. Try to fix the vulnerabilities in the Flask image using the recommendations from Docker Scout.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  6. Docker Debug
&lt;/h2&gt;

&lt;p&gt;&lt;em&gt;Requirement: This step requires the Docker SBOM step to be completed first.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Docker Debug is a tool to debug Docker images and containers. It allows you to run a container with a debug shell, and inspect the image and the container.&lt;/p&gt;

&lt;p&gt;Docker Debug is a paid feature available on Docker Desktop.&lt;/p&gt;

&lt;h3&gt;
  
  
  Usage
&lt;/h3&gt;

&lt;p&gt;Docker Debug can be used to investigate images or containers, when &lt;code&gt;docker exec&lt;/code&gt; is not enough. For example, you can use it to inspect a scratch image:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker debug aerabi/cpp-hello:with-build-stage
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Exercises
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;6.1. Use Docker Debug to inspect the C++ image.&lt;/li&gt;
&lt;li&gt;6.2. Use Docker Debug to inspect the Flask image.&lt;/li&gt;
&lt;li&gt;6.3. Run the Flask image and inspect it with Docker Debug.&lt;/li&gt;
&lt;li&gt;6.4. Install a tool like Vim using Docker Debug. The tools persist between different inspections. Try to inspect another container and check if the tool is still there.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  7. Docker Model Runner
&lt;/h2&gt;

&lt;p&gt;&lt;em&gt;Main article: &lt;a href="https://dev.to/docker/run-genai-models-locally-with-docker-model-runner-5elb"&gt;Run GenAI Models Locally with Docker Model Runner&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Docker Model Runner is a tool to run GenAI models locally using Docker. The feature is still in beta, but is available on Linux, macOS, and Windows.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Linux: Docker CE&lt;/li&gt;
&lt;li&gt;macOS: Docker Desktop 4.40 or later&lt;/li&gt;
&lt;li&gt;Windows: Docker Desktop 4.41 or later&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;On Docker CE, you need to install the Docker Model Runner plugin:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;sudo &lt;/span&gt;apt-get &lt;span class="nb"&gt;install &lt;/span&gt;docker-model-plugin
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Usage
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker model run ai/gemma3
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;To use Docker Model Runner for developing GenAI applications, you can pull the models, and they will become available locally. Whenever an application needs to use a model, it can use the local models.&lt;/p&gt;

&lt;p&gt;And example application is available here:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git clone https://github.com/aerabi/genai-app-demo
&lt;span class="nb"&gt;cd &lt;/span&gt;genai-app-demo
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Edit the file &lt;code&gt;backend.env&lt;/code&gt; and make it match the following content:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;BASE_URL: http://model-runner.docker.internal/engines/llama.cpp/v1/
MODEL: ai/gemma3
API_KEY: ${API_KEY:-dockermodelrunner}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then, run the application:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker compose up &lt;span class="nt"&gt;-d&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Exercises
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;7.1. Docker Compose now supports the &lt;code&gt;model&lt;/code&gt; service type (&lt;a href="https://docs.docker.com/ai/compose/models-and-compose/" rel="noopener noreferrer"&gt;learn more&lt;/a&gt;). Try to adapt the Compose file in the repo to declare the model as a service.&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>docker</category>
    </item>
    <item>
      <title>From Zero to Kubernetes: A Beginner's Guide to Orchestrating Docker Containers</title>
      <dc:creator>Karan Verma</dc:creator>
      <pubDate>Sat, 31 May 2025 12:30:28 +0000</pubDate>
      <link>https://forem.com/docker/from-zero-to-kubernetes-a-beginners-guide-to-orchestrating-docker-containers-leg</link>
      <guid>https://forem.com/docker/from-zero-to-kubernetes-a-beginners-guide-to-orchestrating-docker-containers-leg</guid>
      <description>&lt;p&gt;&lt;strong&gt;Introduction&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;If you've ever built or deployed applications using Docker, you've likely hit a point where running containers on your laptop just isn’t enough. You need scaling, automation, recovery, and networking across machines. Enter Kubernetes, the container orchestrator trusted by startups and tech giants alike. In this beginner-friendly guide, we’ll walk you through what Kubernetes is, why it matters, and how Docker developers can start leveraging its power.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What is Kubernetes?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Kubernetes (also called K8s) is an open-source platform that automates deploying, scaling, and managing containerized applications. While Docker helps package your app into a container, Kubernetes helps run and scale it across many machines.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Frwp2o04bgatzrrim2j8h.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Frwp2o04bgatzrrim2j8h.png" alt="arch" width="800" height="533"&gt;&lt;/a&gt;&lt;br&gt;
Kubernetes architecture explained: The Control Plane manages the cluster while Nodes run Pods, which host your Docker containers.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Why Use Kubernetes?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;- Self-Healing:&lt;/strong&gt; Restarts failed containers automatically.&lt;br&gt;
&lt;strong&gt;- Scalability:&lt;/strong&gt; Scale apps up or down automatically with a single command.&lt;br&gt;
&lt;strong&gt;- Declarative Management:&lt;/strong&gt; Define your infrastructure and app needs using YAML files.&lt;br&gt;
&lt;strong&gt;- Portability:&lt;/strong&gt; Run anywhere from your laptop with Minikube to cloud providers like AWS, GCP, or Azure.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;How Kubernetes Works (for Docker Devs)&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Kubernetes works on a cluster model. A cluster has:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;- Master Node (Control Plane):&lt;/strong&gt; Handles scheduling, scaling, and communication.&lt;br&gt;
&lt;strong&gt;- Worker Nodes:&lt;/strong&gt; Run your Docker containers inside Pods.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Pods and Deployments&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;A Pod is the smallest deployable unit in Kubernetes. It wraps your container(s) and runs on a node. You usually don’t run Pods directly, you use Deployments to manage them.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fq6as56oqoss71o68qqcs.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fq6as56oqoss71o68qqcs.png" alt="Pod &amp;amp; Deployment Flow" width="800" height="800"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Exposing Your App with Services&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Pods can come and go. You need a stable way to expose them; that’s where Services come in. A Service routes traffic to the right Pods and load-balances across them.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fss43jo4u9cb4edxeslyg.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fss43jo4u9cb4edxeslyg.png" alt="Image description" width="800" height="800"&gt;&lt;/a&gt;&lt;br&gt;
Kubernetes Service: Traffic from users is routed through a Service to reach the right Pods, ensuring balanced and reliable access to your app.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Step-by-Step: Try It Yourself with Minikube&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Let’s get hands-on!&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;1. Install Minikube &amp;amp; kubectl&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;brew install minikube
minikube start
kubectl get nodes
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;2. Create a Deployment YAML&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;apiVersion: apps/v1
kind: Deployment
metadata:
  name: my-web-app
spec:
  replicas: 2
  selector:
    matchLabels:
      app: web
  template:
    metadata:
      labels:
        app: web
    spec:
      containers:
      - name: nginx
        image: nginx:latest
        ports:
        - containerPort: 80
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;3. Deploy it to Kubernetes&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;kubectl apply -f deployment.yaml
kubectl get pods
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;4. Expose Your Deployment as a Service&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;kubectl expose deployment my-web-app --type=NodePort --port=80
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;5. Access Your App&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;minikube service my-web-app
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Bonus: Access a Pod Directly (Port Forwarding)&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;kubectl port-forward pod/my-web-app-xxxx 8080:80
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;📚 Further Reading&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Here are some trusted, beginner-friendly resources to deepen your Kubernetes knowledge, especially curated for developers coming from Docker:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="https://kubernetes.io/docs/" rel="noopener noreferrer"&gt;Kubernetes Official Documentation&lt;/a&gt;: The canonical source for Kubernetes knowledge, straight from the maintainers.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="https://docs.docker.com/get-started/orchestration/" rel="noopener noreferrer"&gt;Docker + Kubernetes (Docker Docs)&lt;/a&gt;: Docker’s own guide on moving from Docker CLI to Kubernetes orchestration.  &lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="https://minikube.sigs.k8s.io/docs/start/" rel="noopener noreferrer"&gt;Minikube Official Docs&lt;/a&gt;: Run Kubernetes locally in minutes, perfect for testing and dev environments.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="https://kubernetes.io/docs/reference/kubectl/cheatsheet/" rel="noopener noreferrer"&gt;kubectl Cheat Sheet&lt;/a&gt;: Bookmark this as your go-to for common Kubernetes CLI commands.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="https://docs.digitalocean.com/products/kubernetes/getting-started/deploy-image-to-cluster/" rel="noopener noreferrer"&gt;Build and Deploy Your First Image on DigitalOcean Kubernetes&lt;/a&gt;: A hands-on tutorial that ties together Docker image creation and Kubernetes deployment.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="https://www.youtube.com/watch?v=X48VuDVv0do" rel="noopener noreferrer"&gt;Kubernetes for Beginners (YouTube - TechWorld with Nana)&lt;/a&gt;: A visual, practical walkthrough of key Kubernetes concepts is great for Docker users.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Conclusion&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Kubernetes might seem complex at first, but if you’re already familiar with Docker, you’re well on your way to mastering it. In this guide, you took important first steps by deploying your app, scaling it, and exposing it with a service, all using tools on your own machine. With a bit of practice and curiosity, you’ll soon unlock the full power of Kubernetes to manage containers at scale, whether locally or in the cloud. &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Keep experimenting, and enjoy the journey from zero to Kubernetes pro!&lt;/strong&gt;🚀&lt;/p&gt;

</description>
      <category>kubernetes</category>
      <category>docker</category>
      <category>devops</category>
      <category>cloudnative</category>
    </item>
    <item>
      <title>Docker MCP Catalog &amp; Toolkit: Building Smarter AI Agents with Ease</title>
      <dc:creator>Karan Verma</dc:creator>
      <pubDate>Tue, 20 May 2025 11:43:38 +0000</pubDate>
      <link>https://forem.com/docker/docker-mcp-catalog-toolkit-building-smarter-ai-agents-with-ease-408c</link>
      <guid>https://forem.com/docker/docker-mcp-catalog-toolkit-building-smarter-ai-agents-with-ease-408c</guid>
      <description>&lt;p&gt;&lt;strong&gt;Introduction: What Is Docker MCP and Why It Matters&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The rise of agent-based AI applications, powered by ChatGPT, Claude, and custom LLMs, has created a demand for modular, secure, and standardized integrations with real-world tools. Docker’s Model Context Protocol (MCP), along with its Catalog and Toolkit, addresses this need.&lt;/p&gt;

&lt;p&gt;Docker is positioning itself not just as a container platform but as the infrastructure backbone for intelligent agents. In this post, we’ll explore the MCP architecture, Catalog, and Toolkit, and demonstrate how to build your own MCP server.&lt;/p&gt;

&lt;h2&gt;
  
  
  Section 1: Understanding MCP: The Model Context Protocol
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;What it is:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;MCP is an &lt;strong&gt;open protocol&lt;/strong&gt; that allows AI clients (like agents) to call real-world services securely and predictably.&lt;/li&gt;
&lt;li&gt;It's designed for tool interoperability, secure credential management (handling API keys and tokens), and container-based execution.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Why it matters:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Without standards like MCP, agents rely on brittle APIs or unsafe plugins.&lt;/li&gt;
&lt;li&gt;Docker provides a secure, isolated runtime to host these services in containers.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Visual overview:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fnl9fzxlbty6djtfhhuzn.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fnl9fzxlbty6djtfhhuzn.png" alt="MCP Arch Diagram" width="800" height="533"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;How an AI client communicates with containerized services via MCP&lt;/em&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Section 2: MCP Catalog: Prebuilt, Secure MCP Servers
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;What it includes:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;A growing library of 100+ Docker-verified MCP servers, including:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Stripe&lt;/li&gt;
&lt;li&gt;LangChain&lt;/li&gt;
&lt;li&gt;Elastic&lt;/li&gt;
&lt;li&gt;Pinecone&lt;/li&gt;
&lt;li&gt;Hugging Face&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Key features:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Each MCP server runs inside a container and includes:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;OpenAPI spec&lt;/li&gt;
&lt;li&gt;Secure default config&lt;/li&gt;
&lt;li&gt;Docker Desktop integration&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Why developers care:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Plug-and-play tools for AI agents.&lt;/li&gt;
&lt;li&gt;Consistent dev experience across services.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Visual overview:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fr1awaatmw44r57fm2as3.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fr1awaatmw44r57fm2as3.png" alt="MCP Catalog Diagram" width="800" height="533"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;MCP Catalog integration with Docker Desktop&lt;/em&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Section 3: MCP Toolkit: Build Your Own Secure MCP Server
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Toolkit CLI Features:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;mcp init&lt;/code&gt; → Scaffolds new MCP server&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;mcp run&lt;/code&gt; → Runs local dev version&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;mcp deploy&lt;/code&gt; → Deploy to Docker Desktop&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Security features:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Container isolation&lt;/li&gt;
&lt;li&gt;OAuth support for credentials&lt;/li&gt;
&lt;li&gt;Optional rate limiting and tracing&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Demo walkthrough:&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;npm install -g @docker/mcp-toolkit
mcp init my-weather-api
cd my-weather-api
mcp run
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Visual walkthrough:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fpflyy3al2z9h1nxzhw03.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fpflyy3al2z9h1nxzhw03.png" alt="MCP Toolkit Diagram" width="800" height="533"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;MCP Toolkit Workflow: From CLI to Container&lt;/em&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Section 4: Connecting MCP Servers to AI Clients
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Supported clients:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Claude (Anthropic)&lt;/li&gt;
&lt;li&gt;GPT Agents (OpenAI)&lt;/li&gt;
&lt;li&gt;Docker AI (beta)&lt;/li&gt;
&lt;li&gt;VS Code Extensions&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;How it works:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Agents call &lt;code&gt;/invoke&lt;/code&gt; endpoint defined in MCP spec.&lt;/li&gt;
&lt;li&gt;Secure token exchange handles identity.&lt;/li&gt;
&lt;li&gt;Response returned to model for reasoning/action.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Use case example:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Claude uses a Docker MCP server to call a Stripe payment processing container during an e-commerce interaction.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Visual flow:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fqht7pop4qx9u0lakaito.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fqht7pop4qx9u0lakaito.png" alt="Agent-to-API via Docker MCP" width="800" height="533"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Shows how Claude securely calls a Stripe service via Docker MCP.&lt;/em&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Section 5: Best Practices for MCP Server Developers
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Security:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Never use root containers&lt;/li&gt;
&lt;li&gt;Use &lt;code&gt;docker scan&lt;/code&gt; and &lt;code&gt;trivy&lt;/code&gt; for image vulnerability scanning&lt;/li&gt;
&lt;li&gt;Store secrets with Docker's secret manager (or Vault)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Performance:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Keep containers lightweight (use Alpine or Distroless)&lt;/li&gt;
&lt;li&gt;Use streaming responses for LLM interaction&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Testing tips:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Use &lt;code&gt;Postman&lt;/code&gt; + &lt;code&gt;curl&lt;/code&gt; to test &lt;code&gt;/invoke&lt;/code&gt; endpoint&lt;/li&gt;
&lt;li&gt;Lint OpenAPI specs with &lt;code&gt;swagger-cli&lt;/code&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Section 6: The Future of MCP: What Comes Next?
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Predictions:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Docker AI Dashboard integration&lt;/li&gt;
&lt;li&gt;MCP orchestration (multiple services per agent)&lt;/li&gt;
&lt;li&gt;AI-native DevOps (agents building infra with MCP servers)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Opportunities for devs:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Contribute to open MCP servers&lt;/li&gt;
&lt;li&gt;Submit to Docker Catalog&lt;/li&gt;
&lt;li&gt;Build agent tools for internal or public use&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Closing Thoughts&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Docker’s MCP Catalog and Toolkit are still in beta, but the path forward is clear: AI apps need real-world tool access, and Docker is building a secure, open ecosystem to power it.&lt;/p&gt;

&lt;p&gt;Whether you’re building agent frameworks or just experimenting with tool-using LLMs, now’s the perfect time to get involved.&lt;/p&gt;

&lt;p&gt;Got ideas for MCP servers you want to see? Or thinking about contributing your own? I’d love to hear from you!  😊&lt;/p&gt;

</description>
      <category>dockermcp</category>
      <category>aiagents</category>
      <category>containersecurity</category>
      <category>devopsai</category>
    </item>
  </channel>
</rss>
