AWS CLI Command to remove configured aws credentials (access_key and secret_access_key)

0

I configured the aws credentials in the codebase using command aws config however now I want to remove those credentials and the update the new one but I am unable to remove using the below commands: aws configure unset aws_access_key_id aws configure unset aws_secret_access_key aws configure unset region

Please help me how to achieve this

1개 답변
1
수락된 답변

Hello.

If you run "aws configure" again and enter a new access key etc., it should be overwritten.

aws configure

AWS Access Key ID [*****Z2UD]: *****
AWS Secret Access Key [*****NBuv]: *****
Default region name [ap-northeast-1]: ap-northeast-1
Default output format [json]: json

Alternatively, I think it can be resolved by deleting or rewriting the contents of "~/.aws/credentials" and "~/.aws/config" as described in the StackOverFlow below.
https://stackoverflow.com/questions/46319880/how-do-i-clear-the-credentials-in-aws-configure

profile picture
전문가
답변함 6달 전
profile picture
전문가
검토됨 6달 전

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠