結論
awsの名前付きプロファイルの設定は、
config:[profile user1]
credentialsの場合:[user1]
のようにConfigの場合はprofileを入れる必要がある
configにはprofileが必要
~/.aws/config
[profile user1]
region=us-east-1
output=text
credentialsにはprofileが必要ない
~/.aws/credentials
[user1]
aws_access_key_id=ABCDEFGHIJKLMEXAMPLE
aws_secret_access_key=MAJIDE/MAJIDE/MAJIDE
使い方
--profileで使用する。
$ aws s3 --profile user1 ls
参考資料
https://docs.aws.amazon.com/ja_jp/cli/latest/userguide/cli-configure-profiles.html