Silence the Snyk message after docker build

I find the Synk message after my docker build command distracting because it looks like something went wrong with the build and I want to remove the message. I looked through the environment variables documentation at https://docs.docker.com/engine/reference/commandline/cli/#environment-variables but I didn’t find anything. How do I silence the Snyk message?

The following is an example of the output:

$ docker build -t demoapp .
[+] Building 1.1s (12/12) FINISHED
# ...

Use 'docker scan' to run Snyk tests against images to find vulnerabilities and learn how to fix them

I would also like to silence this Synk message, especially when running docker build --quiet. Including this extra message breaks some local debugging conveniences I use, like

docker run --rm `docker build --quiet .`

since the standard output of the build command is no longer only the built image ID.

Is there a way to opt out of Synk altogether?

set environment variable with:

export DOCKER_SCAN_SUGGEST=false

This will silence the message

1 Like