Skip to content

Conversation

@danielrbradley
Copy link
Contributor

Make cleaning up stacks easier

  • Print instructions on how to retain resources on failure.
  • When retaining resources explain why this is happening and write out a destroy script for the user to run once they've finished their investigations.

Related to #109

Make temp directory cleanup easier to control

  • Maintain existing defaults - keeping files locally on failure by default.
  • Add explicit control via PULUMITEST_RETAIN_FILES_ON_FAILURE with prompting to the user on failure.
  • Default to retaining if we've retained the resources.
  • Finally, check for the CI env var.

@danielrbradley danielrbradley requested review from a team and t0yv0 October 20, 2024 01:06
@danielrbradley danielrbradley self-assigned this Oct 20, 2024
Copy link
Member

@iwahbe iwahbe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the change itself is good.

I'd like to see a less messy way to handle env vars. We don't need to block on it, but I think the cleanup would be worth it.

- Print instructions on how to retain resources on failure.
- When retaining resources explain why this is happening and write out a destroy script for the user to run once they've finished their investigations.

Related to #109
- Maintain existing defaults - keeping locally.
- Add explicit control via PULUMITEST_RETAIN_FILES_ON_FAILURE with prompting to the user on failure.
- Default to retaining if we've retained the resources.
- Finally, check for the `CI` env var.
@danielrbradley danielrbradley merged commit e07c9c9 into main Oct 23, 2024
1 check passed
@danielrbradley danielrbradley deleted the stack-cleanup-help branch October 23, 2024 19:36
@pulumi-bot
Copy link

This PR has been shipped in release v0.1.4.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants