Aws-cli: Clear credentials with aws cli configure

Created on 29 May 2018  路  6Comments  路  Source: aws/aws-cli

Hello everybody 馃憢

I juste want to know if it's possible to remove a named profile credentials with aws cli configure.

Maybe something like that : aws configure rm --profile MY_PROFILE_NAME

Thank you in advanced

feature-request

Most helpful comment

This would be a useful feature to have. I accidentally mistyped a profile name and ended up creating one by mistake.

aws configure set region us-west-1 --profile PROFILE_NAME_oops_typo

I'd like to not see that oops_typo with I list-profiles later. The command should be consistent with the naming conventions used elsewhere:

aws configure delete-profile --profile PROFILE_NAME_oops_typo
Make the --profile option a REQUIRED parameter to avoid deleting the default profile by mistake. If someone wants to delete the default profile they should use --profile default

Would be great if this was available. I've just run into an issue where setting values for the roleArn to "" throws an error of either missing source_profile or mismatch if I put in a soure_profile. Just want to purge the profile altogether so I can re-create it with the correct config. Luckily I'm early in our stages of use of profiles so won't be a major impact to users if I just purge their config file altogether.

All 6 comments

Seems reasonable. Out of curiosity, how would you plan to use this feature? An example would be great. Otherwise, marking as feature request.

We do use this workaround to "simulate" a profile deletion:
aws configure --profile PROFILE_NAME set aws_secret_access_key ''

This would be a useful feature to have. I accidentally mistyped a profile name and ended up creating one by mistake.

aws configure set region us-west-1 --profile PROFILE_NAME_oops_typo

I'd like to not see that oops_typo with I list-profiles later. The command should be consistent with the naming conventions used elsewhere:

aws configure delete-profile --profile PROFILE_NAME_oops_typo
Make the --profile option a REQUIRED parameter to avoid deleting the default profile by mistake. If someone wants to delete the default profile they should use --profile default

This would be a useful feature to have. I accidentally mistyped a profile name and ended up creating one by mistake.

aws configure set region us-west-1 --profile PROFILE_NAME_oops_typo

I'd like to not see that oops_typo with I list-profiles later. The command should be consistent with the naming conventions used elsewhere:

aws configure delete-profile --profile PROFILE_NAME_oops_typo
Make the --profile option a REQUIRED parameter to avoid deleting the default profile by mistake. If someone wants to delete the default profile they should use --profile default

Would be great if this was available. I've just run into an issue where setting values for the roleArn to "" throws an error of either missing source_profile or mismatch if I put in a soure_profile. Just want to purge the profile altogether so I can re-create it with the correct config. Luckily I'm early in our stages of use of profiles so won't be a major impact to users if I just purge their config file altogether.

Not at all working

Our use case for this would be on the build server. We are using Terraform with multiple aws providers so using env vars is not an option. We generate the credentials file, and run our build/deploy. It would be nice to remove the file after completion, so we do not leave secrets on the build server.

Was this page helpful?
0 / 5 - 0 ratings