docker-version-validation

Validate Dockerfile Node.js, pnpm, and turbo versions against package.json constraints.

2|1|Updated Jan 7, 2021
One-click install
npx skills add https://github.com/lsst-sqre/squareone --skill docker-version-validation
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: docker-version-validation
Source: https://github.com/lsst-sqre/squareone/tree/main/.claude/skills/docker-version-validation
Command: npx skills add https://github.com/lsst-sqre/squareone --skill docker-version-validation

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires node, pnpm, and includes scripts (resource) components.

What problem does it solve?

Version inconsistencies between Dockerfiles and package.json lead to unexpected build failures and deployment issues. This skill automates the validation process, ensuring critical tool versions (Node.js, pnpm, Turbo) are always synchronized.

Core Features & Use Cases

  • Automated Version Sync: Validates Node.js, pnpm, and Turbo versions across Dockerfiles and package.json files.
  • Pre-commit & CI Integration: Automatically runs on pre-commit hooks and in CI pipelines, blocking commits or builds with mismatches.
  • Clear Troubleshooting: Provides detailed error messages and guidance for resolving version conflicts.
  • Use Case: When updating the Node.js version in a Dockerfile, use this skill to automatically verify that the package.json engines field is updated correctly, preventing a CI failure later.

Quick Start

Check all Dockerfiles in the repository for version consistency with their package.json files. pnpm validate-docker

Frequently Asked Questions about docker-version-validation

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

FAQPage Schema
How do I prevent Docker and package.json version mismatches from breaking builds?

Version mismatches between Dockerfiles and package.json cause unexpected build failures. This skill automatically validates Node.js, pnpm, and Turbo versions across both files, catching drift before commits or CI runs fail.

Can I automatically sync Node.js versions between Dockerfile and package.json engines?

Yes. The skill validates that Node.js major.minor versions in your Dockerfile match the engines field in package.json, with patch-level tolerance. Run `pnpm validate-docker` to check all Dockerfiles against their corresponding package.json constraints.

How do I enforce exact pnpm and Turbo version consistency in CI pipelines?

The skill integrates into pre-commit hooks and CI pipelines to block commits or builds when pnpm or Turbo versions in Dockerfiles don't match exact versions specified in package.json's packageManager and devDependencies fields.

What happens when Docker versions drift from package.json constraints?

Version drift causes silent build failures—dependencies resolve differently or tools behave unexpectedly. This skill flags mismatches with detailed error messages, helping you resolve conflicts before deployment.

Does this work with monorepos using multiple Dockerfiles?

Yes. The skill scans all Dockerfiles in your repository and validates each against its corresponding package.json file, supporting monorepo structures with multiple package managers or build configurations.

Related Skills