본문 바로가기
Python

Python - AWS Credentials 저장위치, 적용 순서

by 올엠 2022. 5. 16.
반응형

AWS 인증 키는 아래와 같이 적용 할 수 있다.

Python 기준으로 boto에 직접 인증키를 입력하지 않으면, 1번부터 순차적으로 인증키가 있는지 확인을 진행하고 적용이 된다.

 

Passing credentials as parameters in the boto.client() method
Passing credentials as parameters when creating a Session object
1. Environment variables 환경 변수(AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY)
2. Shared credential file (~/.aws/credentials)
3. AWS config file (~/.aws/config)
4. Boto2 config file (/etc/boto.cfg and ~/.boto)
6. Instance metadata service on an Amazon EC2 instance, IAM Role을 통한 RoleBase 인증(EC2에서 IAM Role 부여)

 

댓글0