container-hadolint

Lint Dockerfiles for security best practices and CIS Docker Benchmark compliance.

183|35|Updated Nov 19, 2025
One-click install
npx skills add https://github.com/AgentSecOps/SecOpsAgentKit --skill container-hadolint
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: container-hadolint
Source: https://github.com/AgentSecOps/SecOpsAgentKit/tree/main/skills/devsecops/container-hadolint
Command: npx skills add https://github.com/AgentSecOps/SecOpsAgentKit --skill container-hadolint

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) and assets (resource) components.

What problem does it solve?

Dockerfiles often contain security anti-patterns and outdated practices that expose containers to risk. Hadolint-based linting identifies misconfigurations and policy violations before build, helping teams enforce CIS Docker Benchmark compliance.

Core Features & Use Cases

  • Automated Dockerfile linting against security rules and best practices.
  • CI/CD integration with popular pipelines and code-quality reports.
  • Configurable with dedicated assets and references for remediation guidance.

Quick Start

Run hadolint on your Dockerfile to validate security and style in your development workflow.

Frequently Asked Questions about container-hadolint

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I lint Dockerfiles to enforce CIS Docker Benchmark compliance?

You can lint Dockerfiles to enforce CIS Docker Benchmark compliance by running Hadolint against your build files. This identifies security anti-patterns and policy violations before the container build process begins.

Can I integrate Dockerfile security linting into a CI/CD pipeline?

Yes, Dockerfile security linting integrates directly into CI/CD pipelines. The process validates multiple Dockerfiles and outputs reports in JSON or code-quality formats for automated code review workflows.

How do I configure Hadolint rules for different environments?

You configure Hadolint rules for different environments by using a .hadolint.yaml file. This allows you to set per-environment thresholds, enforce trusted registries, and tailor rule enforcement to your specific needs.

What security anti-patterns does Dockerfile linting catch during local development?

Dockerfile linting catches security anti-patterns and outdated practices during local development. It validates your Dockerfiles against security rules to expose containers to fewer risks before committing code.

Does Dockerfile security linting support code-quality report formats for code reviews?

Yes, Dockerfile security linting supports code-quality report formats for code reviews. It produces validation reports in JSON or code-quality formats to integrate with your existing review infrastructure.