awslabs / awslabs/aws-shell

Profile is not picked up properly using aws-shell

Open
#166 5 comments 0 reactions 0 assignees View on GitHub
bug
Dominant language
Python
Stars
7.3k
Forks
780
PR merge metrics
No merged PRs in 30d

Description

I have two profiles in my .aws folder.
```
> cat config
[office]
output = json
region = us-east-1

[profile personal]
output = json
region = us-east-1
```

When I login to aws-shell I provide the profile
```
> aws-shell -p personal
```

Below is the output of '.profile'
```
aws> .profile
Current shell profile: personal
```

When I did 'ec2 describe-instances' it list all ec2's under my 'office' profile instead of 'personal'.

1. I got a long list of ec2's for the below.
```
aws> ec2 describe-instances
{......}
```

2. While below is the output if I specify --profile for 'ec2 describe-instances' command.
```
aws> ec2 describe-instances --profile personal
{
"Reservations": []
}
```

Since I set profile while entering aws-shell. I would expect both the above two cases (1 and 2) to return the same result i.e. the one returned by 2 (as it is correct). I would expect the same from 1 as well.

I am using aws-shell version (0.1.1)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.