|
1 | 1 | // Module included in the following assemblies: |
2 | 2 | // |
3 | 3 | // * rosa_getting_started/rosa-getting-started.adoc |
| 4 | +// * rosa_getting_started/quickstart.adoc |
4 | 5 |
|
5 | 6 | :_content-type: PROCEDURE |
6 | 7 | [id="rosa-getting-started-deleting-a-cluster_{context}"] |
7 | 8 | = Deleting a ROSA cluster and the AWS STS resources |
8 | 9 |
|
| 10 | +ifeval::["{context}" == "rosa-getting-started"] |
| 11 | +:getting-started: |
| 12 | +endif::[] |
| 13 | +ifeval::["{context}" == "rosa-quickstart"] |
| 14 | +:quickstart: |
| 15 | +endif::[] |
| 16 | + |
9 | 17 | You can delete a ROSA cluster that uses the AWS Security Token Service (STS) by using the ROSA CLI (`rosa`). You can also use the ROSA CLI to delete the AWS Identity and Access Management (IAM) account-wide roles, the cluster-specific Operator roles, and the OpenID Connect (OIDC) provider. To delete the account-wide inline and Operator policies, you can use the AWS IAM Console. |
10 | 18 |
|
11 | 19 | [IMPORTANT] |
12 | 20 | ==== |
13 | 21 | Account-wide IAM roles and policies might be used by other ROSA clusters in the same AWS account. You must only remove the resources if they are not required by other clusters. |
14 | 22 | ==== |
15 | 23 |
|
| 24 | +ifdef::getting-started[] |
16 | 25 | .Prerequisites |
17 | 26 |
|
18 | 27 | * You installed and configured the latest AWS (`aws`), ROSA (`rosa`), and OpenShift (`oc`) CLIs on your workstation. |
19 | 28 | * You logged in to your Red Hat account by using the `rosa` CLI. |
20 | 29 | * You created a ROSA cluster. |
| 30 | +endif::[] |
21 | 31 |
|
22 | 32 | .Procedure |
23 | 33 |
|
@@ -56,20 +66,27 @@ $ rosa delete operator-roles -c <cluster_id> --mode auto <1> |
56 | 66 |
|
57 | 67 | . Delete the account-wide roles: |
58 | 68 | + |
| 69 | +[IMPORTANT] |
| 70 | +==== |
| 71 | +Account-wide IAM roles and policies might be used by other ROSA clusters in the same AWS account. You must only remove the resources if they are not required by other clusters. |
| 72 | +==== |
| 73 | ++ |
59 | 74 | [source,terminal] |
60 | 75 | ---- |
61 | 76 | $ rosa delete account-roles --prefix <prefix> --mode auto <1> |
62 | 77 | ---- |
63 | 78 | <1> You must include the `--<prefix>` argument. Replace `<prefix>` with the prefix of the account-wide roles to delete. If you did not specify a custom prefix when you created the account-wide roles, specify the default prefix, `ManagedOpenShift`. |
64 | | -+ |
65 | | -[IMPORTANT] |
66 | | -==== |
67 | | -Account-wide IAM roles and policies might be used by other ROSA clusters in the same AWS account. You must only remove the resources if they are not required by other clusters. |
68 | | -==== |
69 | 79 |
|
70 | 80 | . Delete the account-wide inline and Operator IAM policies that you created for ROSA deployments that use STS: |
71 | 81 | .. Log in to the link:https://console.aws.amazon.com/iamv2/home#/home[AWS IAM Console]. |
72 | 82 | .. Navigate to *Access management* -> *Policies* and select the checkbox for one of the account-wide policies. |
73 | 83 | .. With the policy selected, click on *Actions* -> *Delete* to open the delete policy dialog. |
74 | 84 | .. Enter the policy name to confirm the deletion and select *Delete* to delete the policy. |
75 | 85 | .. Repeat this step to delete each of the account-wide inline and Operator policies for the cluster. |
| 86 | + |
| 87 | +ifeval::["{context}" == "rosa-getting-started"] |
| 88 | +:getting-started: |
| 89 | +endif::[] |
| 90 | +ifeval::["{context}" == "rosa-quickstart"] |
| 91 | +:quickstart: |
| 92 | +endif::[] |
0 commit comments