rules-docker

Validate Docker compose files and Dockerfiles for best practices.

Updated May 20, 2025
One-click install
npx skills add https://github.com/flext-sh/flext --skill rules-docker
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: rules-docker
Source: https://github.com/flext-sh/flext/tree/main/.claude/skills/rules-docker
Command: npx skills add https://github.com/flext-sh/flext --skill rules-docker

SYSTEM DOCUMENTATION & REQUIREMENTS

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

What problem does it solve?

This Skill ensures consistency and adherence to best practices for Docker assets within the docker/ directory, preventing common configuration errors and improving maintainability.

Core Features & Use Cases

  • Compose File Validation: Checks for consistent naming, explicit configurations, and absence of placeholder files.
  • Dockerfile Best Practices: Enforces rules like the presence of HEALTHCHECK and avoidance of :latest tags.
  • Use Case: When updating docker-compose.flext.yml or adding a new service definition, this Skill will automatically flag any deviations from established rules, such as missing health checks or the use of floating image tags.

Quick Start

Run the docker standardization script to validate all compose files and Dockerfiles in the docker directory.

Frequently Asked Questions about rules-docker

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

FAQPage Schema
How do I validate Docker compose files for consistent service naming and explicit configurations?

Docker compose validation checks service naming consistency, explicit configurations, and absence of placeholder files within the `docker/` directory to prevent common configuration errors and improve maintainability.

What are the best practices for enforcing Dockerfile standards like health checks and pinned tags?

Dockerfile best practices enforce the presence of `HEALTHCHECK` instructions and avoid `:latest` tags by requiring pinned image tags, ensuring container orchestration and image standardization.

Can I automatically flag missing health checks or floating image tags in my Docker configurations?

Yes, running the docker standardization script automatically flags deviations from established rules, such as missing health checks or the use of floating image tags, when updating compose files or adding services.

Does Docker standardization require assets to be in a specific directory structure?

Docker standardization validates compose files and Dockerfiles specifically within the `docker/` directory, ensuring consistency and adherence to best practices for all assets located there.

What is the best way to check for network consistency and explicit settings across container orchestration assets?

The standardization script validates network consistency, explicit configurations, and service naming rules across compose files to address scenarios involving container orchestration and image standardization.