982 words
5 min read

Mastering Docker Scout through Docker Desktop GUI and CLI

By · Solutions Architect · Docker Captain · IBM Champion
Cover image for the post 'Mastering Docker Scout through Docker Desktop GUI and CLI'

Docker Scout shows you direct and transitive dependencies in one place, across every image layer. That alone makes container security easier to reason about. I wrote about why it matters before, here: Docker Scout is the Game-Changer in Container Security.

This one is about the how. I’ll run Docker Scout in live use. Both the Docker Desktop GUI and the CLI.

So what does it actually do? Docker Scout reads the contents of an image, reports the packages and vulnerabilities inside, and suggests a fix for each. It also flags updates for your base image, with the tags and digests it recommends. You can filter images by vulnerability data too.

Installing Docker Scout#

You need Docker Desktop to run Docker Scout. It works on Linux, macOS, and Windows. The Docker CLI ships with it, so you already have what you need.

Don’t have it yet? Grab Docker Desktop from the official Docker website.

Installing Docker Scout on a server#

To deploy Docker Scout on a server, run this:

Terminal window
curl -sSfL https://raw.githubusercontent.com/docker/scout-cli/main/install.sh | sh -s --

Manual installation#

Download the docker-scout binary for your platform from the latest or other releases.

  • Uncompress Docker Scout as:
    • docker-scout on Linux and macOS
    • docker-scout.exe on Windows
  • Copy Docker Scout in your local CLI plugin directory:
    • $HOME/.docker/cli-plugins on Linux and macOS
    • %USERPROFILE%\.docker\cli-plugins on Windows
  • Make Docker Scout executable on Linux and macOS:
    • chmod +x $HOME/.docker/cli-plugins/docker-scout
  • Authorize the binary to be executable on macOS:
    • xattr -d com.apple.quarantine $HOME/.docker/cli-plugins/docker-scout

Mastering Docker Scout via Docker Desktop GUI#

Run the latest Docker Desktop. Then open the “Images” section in the menu.

NOTE

In this guide, we will conduct a thorough examination of the security vulnerabilities associated with the Mattermost image.

Want the full setup for that image? I walk through it in Installing Mattermost with Docker Compose.

The “Local” tab lists every image on your system. Nothing there? Pull one with the docker pull command.

Now click the image you want to check.

Mastering Docker Scout through Docker Desktop GUI and CLI - Step 1

The “Vulnerabilities” tab gives you a report on every security issue in the image.

Mastering Docker Scout through Docker Desktop GUI and CLI - Step 2

Next, click “Recommended fixes” and pick “Recommendations for base image” to see what Scout suggests.

Mastering Docker Scout through Docker Desktop GUI and CLI - Step 3

Here, refreshing the base image is one option.

Check the “Refresh base image” tab for those recommendations.

Mastering Docker Scout through Docker Desktop GUI and CLI - Step 4

Or swap the base image entirely.

Check the “Change base image” tab for that.

Mastering Docker Scout through Docker Desktop GUI and CLI - Step 5

Mastering Docker Scout via CLI#

Now the CLI. A few commands carry most of the weight:

docker scout quickview: This command provides a succinct summary of an image, enabling you to get a quick understanding of its main features.

docker scout cves: This command reveals the Common Vulnerabilities and Exposures (CVEs) detected for any software artifacts found within an image, keeping you informed about potential security risks.

docker scout recommendations: With this command, you’ll receive a list of all possible base image updates and remediation suggestions, guiding you on how to improve your container security and efficiency.

docker scout compare: This command allows you to compare two distinct images, highlighting their differences. This feature is particularly useful when you’re tracking changes or considering updates.

Learn these four and you cover most of the day-to-day work.

NOTE

This guide walks you through connecting to a server with the iTerm2 terminal emulator on macOS.

We will conduct a thorough examination of the security vulnerabilities associated with the Mattermost image.

Need the install steps first? See Installing Mattermost with Docker Compose.

Start with a quick summary of the image:

Terminal window
docker scout quickview mattermost/mattermost-team-edition:release-7.11

Mastering Docker Scout through Docker Desktop GUI and CLI - Step 6

Next, pull the CVEs found across the artifacts in the image:

Terminal window
docker scout cves mattermost/mattermost-team-edition:release-7.11

Mastering Docker Scout through Docker Desktop GUI and CLI - Step 7

Now list the base image updates and remediation suggestions:

Terminal window
docker scout recommendations mattermost/mattermost-team-edition:release-7.11

Mastering Docker Scout through Docker Desktop GUI and CLI - Step 8

Scroll up for the rest.

Mastering Docker Scout through Docker Desktop GUI and CLI - Step 9

Now compare two images and see what differs. Here, two Mattermost releases.

Terminal window
docker scout compare --to mattermost/mattermost-team-edition:release-7.11 mattermost/mattermost-team-edition:release-7.10

Mastering Docker Scout through Docker Desktop GUI and CLI - Step 10

Scroll up for the rest.

Mastering Docker Scout through Docker Desktop GUI and CLI - Step 11

Mastering Docker Scout through Docker Desktop GUI and CLI - Step 12

Mastering Docker Scout via CLI in the container#

You don’t always need the plugin installed. You can run Scout straight from a container.

NOTE

This guide walks you through connecting to a server with the iTerm2 terminal emulator on macOS.

We will conduct a thorough examination of the security vulnerabilities associated with the Mattermost image.

Same as before, the install guide is here: Installing Mattermost with Docker Compose.

Start with the quick summary:

Terminal window
docker run -it \
-e DOCKER_SCOUT_HUB_USER=YOUR_DOCKER_HUB_USER_NAME \
-e DOCKER_SCOUT_HUB_PASSWORD=YOUR_DOCKER_HUB_PASSWORD_OR_ACCESS_TOKEN \
docker/scout-cli quickview mattermost/mattermost-team-edition:release-7.11

Mastering Docker Scout through Docker Desktop GUI and CLI - Step 13

Then the CVEs found across the artifacts in the image:

Terminal window
docker run -it \
-e DOCKER_SCOUT_HUB_USER=YOUR_DOCKER_HUB_USER_NAME \
-e DOCKER_SCOUT_HUB_PASSWORD=YOUR_DOCKER_HUB_PASSWORD_OR_ACCESS_TOKEN \
docker/scout-cli cves mattermost/mattermost-team-edition:release-7.11

Mastering Docker Scout through Docker Desktop GUI and CLI - Step 14

Now the base image updates and remediation suggestions:

Terminal window
docker run -it \
-e DOCKER_SCOUT_HUB_USER=YOUR_DOCKER_HUB_USER_NAME \
-e DOCKER_SCOUT_HUB_PASSWORD=YOUR_DOCKER_HUB_PASSWORD_OR_ACCESS_TOKEN \
docker/scout-cli recommendations mattermost/mattermost-team-edition:release-7.11

Mastering Docker Scout through Docker Desktop GUI and CLI - Step 15

And compare two releases, same as before:

Terminal window
docker run -it \
-e DOCKER_SCOUT_HUB_USER=YOUR_DOCKER_HUB_USER_NAME \
-e DOCKER_SCOUT_HUB_PASSWORD=YOUR_DOCKER_HUB_PASSWORD_OR_ACCESS_TOKEN \
docker/scout-cli compare \
--to mattermost/mattermost-team-edition:release-7.11 \
mattermost/mattermost-team-edition:release-7.10

Mastering Docker Scout through Docker Desktop GUI and CLI - Step 16

Scroll up for the rest.

Mastering Docker Scout through Docker Desktop GUI and CLI - Step 17

Mastering Docker Scout through Docker Desktop GUI and CLI - Step 18

Conclusion#

That’s the walkthrough. Docker Scout from the Desktop GUI and from the CLI, both. Container security should sit near the top of your list, and Scout earns a spot in the workflow fast. Wire it in. You get fewer surprises in your images, and a base you can actually trust.


Vladimir Mikhalev

Docker Captain  ·  IBM Champion  ·  AWS Community Builder

The Verdict — production-tested analysis on YouTube.

The Verdict

Inconvenient truths about shipping in the AI era

Container security, platform engineering, and the agentic shift — tested in production, argued without the hype. The verdict reaches your inbox the moment there's one worth sending.

Related Posts

Same category
  1. 1
    Docker supply chain hardening — from Scout D to OpenSSF 7.8 on a 730K-pull image
    DevOps & Cloud · How I hardened a 730K-pull public Docker image from Scout grade D to OpenSSF Scorecard 7.8. Multi-stage build, cosign signing, SLSA provenance, non-root default, and the incident that changed how I ship attestations.
  2. 2
    Cloudflare Web Analytics on Astro — Why Removing GA4 Unlocked Lighthouse 100
    DevOps & Cloud · How removing Google Analytics 4 from an Astro site unlocked Lighthouse 100, why Cloudflare Web Analytics replaced it, and what the tradeoffs actually cost.
  3. 3
    Platform Engineering — The Complete, Practical Guide to Building Internal Developer Platforms That Scale
    DevOps & Cloud · A deep, practical guide to Platform Engineering. Learn how to build internal developer platforms, golden paths, GitOps workflows, and scalable cloud foundations.
  4. 4
    Amazon Q vs DevOps Chaos — Can This AI Fix AWS Faster Than You?
    DevOps & Cloud · Fix AWS issues faster with Amazon Q, the AI assistant built for DevOps. Real-world examples, limitations, and how it compares to ChatGPT.

Random Posts

Random
  1. 1
    Mastering Terraform Contains and Strcontains Functions
    DevOps & Cloud · Learn how to use Terraform's contains and strcontains functions for better logic control in IaC. Includes practical DevOps examples and best practices.
  2. 2
    Install Rocket.Chat Using Docker Compose
    Self-Hosting · Step-by-step guide to install Rocket.Chat on Ubuntu Server using Docker Compose and Traefik with Let's Encrypt SSL. Ideal for secure team communication..
  3. 3
    Install Active Directory Domain Services on Windows Server 2012 R2
    SysAdmin & IT Pro · Learn how to install and configure Active Directory Domain Services (AD DS) on Windows Server 2012 R2 step-by-step using Server Manager. Ideal for sysadmins.
  4. 4
    Install Active Directory Domain Services on Windows Server 2019
    SysAdmin & IT Pro · Step-by-step guide to install and configure Active Directory Domain Services (AD DS) on Windows Server 2019 using Server Manager. Ideal for IT pros and sysadmins.
Mastering Docker Scout through Docker Desktop GUI and CLI
https://heyvaldemar.com/mastering-docker-scout-through-docker-desktop-gui-and-cli/
Author
Vladimir Mikhalev
Published
2023-07-16
License
CC BY-NC-SA 4.0