hadolint
Dockerfile linter that parses AST and integrates with ShellCheck to validate Docker best practices and bash code in RUN instructions
Hadolint is a Dockerfile linter that parses Dockerfiles into an Abstract Syntax Tree (AST) and applies rules to validate Docker best practices. The tool integrates with ShellCheck to lint bash code inside RUN instructions, providing comprehensive validation beyond basic Dockerfile syntax. It supports multiple output formats including TTY, JSON, checkstyle, codeclimate, and SARIF.
The linter offers extensive configuration options through YAML config files, supporting rule severity overrides, trusted registry validation, and label schema enforcement. Users can ignore specific rules globally or inline, set failure thresholds, and customize rule severity levels (error, warning, info, style). Hadolint validates trusted registries in FROM instructions and can enforce specific label schemas with format requirements.
Hadolint runs as a standalone binary or through Docker containers, making it suitable for local development and CI/CD pipelines. It provides both minimal containers and variants with shell access (Debian/Alpine). The tool integrates with various development environments including VS Code extensions and supports configuration through environment variables or command-line options.
Installation
# via Homebrew
brew install hadolint
# via Docker
docker pull hadolint/hadolint
# via Scoop (Windows)
scoop install hadolint

Alternatives & related tools
ShellCheck
Static analysis tool that identifies syntax errors, semantic problems, and pitfalls in bash/sh shell scripts
GDB dashboard
A standalone .gdbinit written in Python that shows a modular dashboard of program state in GDB each time the debugged program stops.
tsx
TypeScript Execute (tsx): a CLI for running TypeScript files directly in Node.js.
ipatool
CLI for searching the App Store for iOS, iPadOS, tvOS, visionOS and macOS apps and downloading .ipa or macOS .pkg packages.
npm-check-updates
CLI that upgrades package.json dependencies to their latest versions, preserving semver range operators. Works with npm, yarn, pnpm, deno, and bun.
add a badge to your README
Maintain hadolint? Show that it's featured on trmn. The badge links back to this page.
[](https://www.trmn.sh/tools/hadolint?utm_source=badge)<a href="https://www.trmn.sh/tools/hadolint?utm_source=badge"><img src="https://www.trmn.sh/badge/hadolint.svg" alt="Featured on trmn" height="20"></a>