Official Dagger Modules
Product by Dagger
The standard library of portable tools for Dagger CI pipelines.
Official Dagger Modules provide a standard library of containerized tools for testing, building, and linting code across any environment. They enable developers to replace complex CI YAML with portable, programmable workflows that run identically from local dev to Dagger Cloud.
Category: Developer Tools
- Platforms
- Linux, macOS, Windows, Dagger Cloud
- Where to buy
- Available via the Dagger CLI (dagger module install)
- Testing Frameworks
- Jest, Vitest, Pytest, Playwright
- Formatting Tools
- Prettier, Biome, Deno fmt
- Infrastructure Tools
- Helm, Kubernetes
- Installation Command
- dagger module install
- Standard library for testing, building, and linting code
- Identical execution across local, CI, and Cloud environments
- Support for Go, Python, JS/TS, Deno, and Shell scripts
- Automated Helm chart linting and template validation
- Native integration with Dagger Engine and Dagger Cloud
Overview
Official Dagger Modules are a standard library of pre-built tools designed to provide consistent build, test, and linting capabilities across the entire development lifecycle. Built for developers and DevOps teams, these modules solve the problem of configuration drift by replacing proprietary CI YAML with programmable modules that read native project configurations. They cover a wide range of ecosystems including Go, Python, JavaScript, TypeScript, Deno, and shell scripting. Every module is designed to run identically on a developer's local machine, within traditional CI pipelines, and on Dagger Cloud. By exposing typed artifacts such as binaries and test results, these modules allow for advanced automation like pre-merge gates and interactive debugging in failed environments.
Language and Framework Support
- Go Development: The Go module provides a standard library of tools to test, build, and run generators for Go packages within a workspace.
- Deno Projects: Deno support includes tools to test, lint, format, and type-check Deno projects and workspaces.
- Python testing is supported through the Pytest module for running test suites.
- JS/TS Testing Frameworks: JavaScript and TypeScript testing is handled by dedicated modules for Jest and Vitest.
Linting and Formatting
- Go Linting: The golangci-lint and Staticcheck modules provide automated linting and analysis for Go projects.
- Web Linting: JavaScript and TypeScript source code can be linted using the ESLint or Biome modules.
- Code Formatting: The Prettier and Biome modules check and rewrite source formatting to maintain code standards.
- Script Analysis: Shell scripts and PowerShell scripts are analyzed using ShellCheck and PSScriptAnalyzer respectively.
Testing and Automation
- Playwright Browser Testing: The Playwright module runs browser tests that are wired directly to the service under test.
- Kubernetes and Helm: The Helm module lints Helm charts and checks rendered templates for Kubernetes deployments.
- Generators and Repairs: Modules expose generators and repair workflows that run the same way locally, in CI, and in Dagger Cloud.
- Automatic Recommendations: Dagger recommends specific official modules for a repository based on the detected toolchains.
Use cases
- Developers use the Go module to run tests and build binaries locally with the same environment used in CI.
- DevOps engineers use the Helm module to validate charts and templates before deploying to Kubernetes.
- Teams use the ESLint and Prettier modules to enforce consistent code style across JavaScript and TypeScript projects.
- QA engineers use the Playwright module to execute browser-based integration tests wired to ephemeral service containers.
- Automation scripts use the ShellCheck module to verify the integrity of shell scripts across different platforms.
Specifications
- Platforms
- Linux, macOS, Windows, Dagger Cloud
- Where to buy
- Available via the Dagger CLI (dagger module install)
- How to get it
- Install into a project using the dagger module install command followed by the module address
- Supported Languages
- Go, Python, JavaScript, TypeScript, Deno, PHP, Java, Elixir, Rust,.NET
- Testing Frameworks
- Jest, Vitest, Pytest, Playwright
- Linting Tools
- golangci-lint, Staticcheck, ESLint, ShellCheck, PSScriptAnalyzer, Biome
- Formatting Tools
- Prettier, Biome, Deno fmt
- Infrastructure Tools
- Helm, Kubernetes
- Installation Command
- dagger module install
- Execution Environment
- Dagger Engine (Containerized)
- Version Status
- 1.0-beta
How it works
- Discovery and Recommendation: Dagger detects the toolchains used in your repository and recommends the appropriate official modules.
- Module Installation: Run 'dagger module install' followed by the module address (e.g., dagger.io/go) to add the tool to your project.
- Configuration and Discovery: The module reads your native configuration to eliminate proprietary YAML and discover project artifacts like source code and tests.
- Execution of Checks: Call the module's functions via the Dagger CLI or API to run checks, generators, or repair workflows.
FAQ
What are official Dagger modules?
Official Dagger modules are the standard library of tools for a workspace to perform tasks like testing code, linting source, or validating Helm charts.
How do I install a Dagger module?
You can add any official module to your project by running the command 'dagger module install' followed by the module name, such as 'dagger.io/go'.
Do modules work differently in CI than they do locally?
Dagger modules are designed to be portable, ensuring that tools like linters and test runners run identically on a local machine, in CI systems, and in Dagger Cloud.
Does Dagger recommend modules for my project?
Yes, Dagger detects your toolchains and recommends official modules for them to help you get started quickly.
Added by AntSpace from public sources (docs.dagger.io).