Supprimer un groupe

Vous pouvez supprimer un groupe d’utilisateurs de votre compte dont vous n’avez plus besoin. Vous pouvez ensuite réutiliser le nom du groupe pour un nouveau groupe.

Cette action ne supprime ni les utilisateurs ni les politiques du groupe, que vous devez supprimer individuellement. Pour en savoir plus, voir Supprimer un utilisateur ou Supprimer une politique gérée.

Supprimer un groupe avec Cockpit v2

  1. Dans le dashboard EIM Groups, cochez la case du groupe que vous voulez supprimer.
    Le groupe est sélectionné.

  2. Cliquez sur IconTerminate Supprimer.
    Une boîte de dialogue de confirmation apparaît.

  3. Dans la boîte de dialogue de confirmation, entrez "SUPPRIMER" dans le champ de texte et cliquez sur Supprimer.
    Le groupe est supprimé.

Supprimer un groupe avec OSC CLI

À ce jour, cette section est disponible en anglais uniquement.

The DeleteUserGroup command deletes a specified user group.

The user group must be empty of any user and must not have any linked policy. Otherwise, you need to force the deletion.
If you force the deletion, all inline policies will be deleted with the user group.

Request sample
$ osc-cli api DeleteUserGroup --profile "default" \
    --Force False \
    --Path "/example/" \
    --UserGroupName "example-usergroup"

This command contains the following attributes that you need to specify:

  • DryRun: (optional) If true, checks whether you have the required permissions to perform the action.

  • Force: (optional) If true, forces the deletion of the user group even if it is not empty.

  • Path: (optional) The path to the group. If not specified, it is set to a slash (/).

  • UserGroupName: The name of the group you want to delete.

The DeleteUserGroup command returns the following elements:

  • ResponseContext: Information about the context of the response.

    • RequestId: The ID of the request.

Result sample
{
  "ResponseContext": {
    "RequestId": "0475ca1e-d0c5-441d-712a-da55a4175157"
  }
}

Supprimer un groupe avec oapi-cli

À ce jour, cette section est disponible en anglais uniquement.

The DeleteUserGroup command deletes a specified user group.

The user group must be empty of any user and must not have any linked policy. Otherwise, you need to force the deletion.
If you force the deletion, all inline policies will be deleted with the user group.

Request sample
$ oapi-cli --profile "default" DeleteUserGroup \
    --Force False \
    --Path "/example/" \
    --UserGroupName "example-usergroup"

This command contains the following attributes that you need to specify:

  • DryRun: (optional) If true, checks whether you have the required permissions to perform the action.

  • Force: (optional) If true, forces the deletion of the user group even if it is not empty.

  • Path: (optional) The path to the group. If not specified, it is set to a slash (/).

  • UserGroupName: The name of the group you want to delete.

The DeleteUserGroup command returns the following elements:

  • ResponseContext: Information about the context of the response.

    • RequestId: The ID of the request.

Result sample
{
  "ResponseContext": {
    "RequestId": "0475ca1e-d0c5-441d-712a-da55a4175157"
  }
}

Supprimer un groupe avec AWS CLI

Avant de commencer :

Pour supprimer un groupe, utilisez la commande delete-group en suivant cette syntaxe :

Exemple de requête
$ aws iam delete-group \
    --profile YOUR_PROFILE \
    --group-name GROUP_NAME \
    --endpoint https://eim.eu-west-2.outscale.com

Cette commande contient les attributs suivants que vous devez spécifier :

  • (optionnel) profile : Le profil nommé que vous voulez utiliser, créé pendant la configuration d’AWS CLI. Pour en savoir plus, voir Installer et configurer AWS CLI.

  • group-name : Le nom du groupe que vous voulez supprimer.

  • endpoint : Le endpoint correspondant à la Région à laquelle vous voulez envoyer la requête. Pour en savoir plus, voir Installer et configurer AWS CLI.

Le groupe spécifié est supprimé de votre compte.

Pages connexes

Méthode API correspondante

AWS™ et Amazon Web Services™ sont des marques de commerce d’Amazon Technologies, Inc. ou de ses affiliées aux États-Unis et/ou dans les autres pays.