pulumi-modify-existing
Installation
SKILL.md
Pulumi: Modify Existing Files
Always modify, never create
Infrastructure changes belong in the existing entrypoint for the stack
(typically __main__.py). Do not create additional Pulumi files unless the stack
already follows a multi-file pattern that makes a new file the right fit.
Preserve existing functionality
When editing a Pulumi stack entrypoint, the following must never be silently removed:
assumeRole/ cross-account role configuration — removing this breaks production deployments that depend on cross-account access.- Existing resource exports (
pulumi.export(...)). - Stack references to other stacks.
Before finalizing changes, scan the diff to confirm nothing was deleted unintentionally.
Validate changes before declaring done
After modifying any Pulumi code, run a preview to confirm the plan is correct:
pulumi preview --stack <stack-name>
Review the output carefully:
- Unexpected resource replacements or deletions are bugs, not acceptable side effects.
- "0 changes" is only correct if you genuinely expected no changes.
Related skills