docs icon indicating copy to clipboard operation
docs copied to clipboard

Best Practices: Authoring, Testing, and Publishing Components

Open jkodroff opened this issue 6 months ago • 3 comments

Create a page in the docs for best practices around the full lifecycle of authoring components.

Some topics to cover:

  • What should go in a component? What makes for a good abstraction? (coherence, needs to actually abstract something)
  • What's the local dev process/SDLC for developing components? How to test locally?
  • What should the outputs of a component be? (typically, all of the resources in the tree)
  • What should CI/CD look like for components?
  • How to ensure that changes are not breaking? (using Pulumi's integration testing framework, creating a test bench locally, or changing the linking to local copies the component)
  • How to roll out changes that are necessarily breaking?

We should note that the what we advise is a way of doing things that we are confident works, but is not necessarily optimal for every organization.

jkodroff avatar Jun 01 '25 23:06 jkodroff

  • Component testing in the pulumi-go-provider framework

automagic avatar Jun 03 '25 15:06 automagic

From a duplicate issue:

  • When do you need a component? (When there's multiple downstream repos/teams consuming it.)
  • How should I structure my repos? (Usually all templates in 1 repo. Components have a couple of options.)
  • How do you test a component locally, mostly to ensure no breaking changes, recreates, etc.? (By creating a Pulumi program in the same repo that serves as a test bench, or by linking to a local copy of the components from your templates repo.)
  • How do I version my components? (Semantically.)

jkodroff avatar Jun 21 '25 02:06 jkodroff

Related: https://github.com/pulumi/pulumi/issues/19921

jkodroff avatar Jun 22 '25 21:06 jkodroff