pulumi-component

Installation
Summary

Reusable infrastructure components with multi-language support, sensible defaults, and composition patterns.

  • Requires four core elements: extend ComponentResource, accept standard parameters, set parent: this on all children, and call registerOutputs() at the end of the constructor
  • Args interfaces must use Input<T> wrappers, avoid union types and functions, and keep structures flat to support multi-language SDK generation
  • Expose only essential outputs as public properties; hide implementation details and derive composite values using pulumi.interpolate
  • Multi-language components require a PulumiPlugin.yaml entry point and can be distributed via private registry, git tags, package managers, or the public Pulumi Registry
  • Common patterns include sensible defaults with override, conditional resource creation, composition of lower-level components, and provider passthrough for multi-region deployments
SKILL.md

Authoring Pulumi Components

A ComponentResource groups related infrastructure resources into a reusable, logical unit. Components make infrastructure easier to understand, reuse, and maintain. Components appear as a single node with children nested underneath in pulumi preview/pulumi up output and in the Pulumi Cloud console.

This skill covers the full component authoring lifecycle. For general Pulumi coding patterns (Output handling, secrets, aliases, preview workflows), use the pulumi-best-practices skill instead.

When to Use This Skill

Invoke this skill when:

  • Creating a new ComponentResource class
  • Designing the args interface for a component
  • Making a component consumable from multiple Pulumi languages
  • Publishing or distributing a component package
  • Refactoring inline resources into a reusable component
  • Debugging component behavior (missing outputs, stuck creating, children at wrong level)

Component Anatomy

Related skills

More from pulumi/agent-skills

Installs
646
GitHub Stars
45
First Seen
Jan 28, 2026