2 DL1001
Moritz Röhrich edited this page 2026-04-30 11:21:13 +02:00

Please refrain from using inline ignore pragmas # hadolint ignore=DLxxxx.

Problematic code:

# hadolint ignore=DL3006
FROM busybox

Correct code:

FROM busybox

Rationale:

Using inline ignore pragmas can hide legitimate issues and make it harder to maintain code quality standards across an entire organization. This rule can be used to enforce that no inline ignore pragma is used in a Dockerfile. Inline ignore pragmas open up the possiblity to create Dockerfiles which violate best practices and force Hadolint's checks to pass anyways. Should a user or organization not want to permit this, they can elevate the severity of this rule. In that case, all uses of inline ignore pragmas will automatically lead to a warning by Hadolint.


This rule is disabled by default. To enable configure Hadolint:

override:
  warning:
    - DL1001