Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OCM-5358 | fix: add a warning message when using best effort deletion #1668

Merged
merged 1 commit into from
Dec 26, 2023

Conversation

oriAdler
Copy link
Contributor

Notify the user about cloud resources that may left behind when using the 'best effort' flag.

@openshift-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Dec 21, 2023
cmd/dlt/cluster/cmd.go Outdated Show resolved Hide resolved
@@ -85,6 +85,11 @@ func run(cmd *cobra.Command, _ []string) {

cluster := r.FetchCluster()

if args.bestEffort {
r.Reporter.Warnf("Deleting a cluster with 'best effort' means that certain resources may be left behind " +
Copy link
Contributor

@robpblake robpblake Dec 21, 2023

Choose a reason for hiding this comment

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

@oriAdler Wondering if we should include the clusterKey and AWS account details in this message so something like:

r.Reporter.Warnf("Deleting cluster '%s' with 'best effort' means that certain resources may be left behind in AWS account '%s'. These resources will need to be deleted manually.", r.GetClusterKey(),r.Creator.AccountID)

Just makes it a little more helpful to the user to verify that they're deleting the correct cluster and which AWS account might have resources left over.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Good point, added, thanks.

Notify the user about cloud resources that may left behind when using
the 'best effort' flag.
Copy link
Contributor

openshift-ci bot commented Dec 26, 2023

@oriAdler: all tests passed!

Full PR test history. Your PR dashboard.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@gdbranco
Copy link
Contributor

/lgtm

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Dec 26, 2023
Copy link
Contributor

openshift-ci bot commented Dec 26, 2023

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: gdbranco, oriAdler

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-merge-bot openshift-merge-bot bot merged commit 77070fa into openshift:master Dec 26, 2023
6 checks passed
@oriAdler oriAdler deleted the OCM-5358 branch March 20, 2024 11:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants