Closed trondhindenes closed 6 years ago
Thanks for the kind words!
Right now saw reads the region from your profile, usually whatever is in ~/.aws/config
. This is a what mine looks like:
[profile default]
output = json
region = us-east-1
[profile west]
output = json
region = us-west-1
I know this isn't an ideal solution but the AWS Golang library lets you set a region using environment variables:
export AWS_REGION=us-west-1
Or, if you have another profile that is in a different region
export AWS_PROFILE=my-profile-in-other-region
This is great feedback though as I should add both a flag for region and one that lets you specify another profile. I'll work on that next!
I think the region is hard coded to us-east-1 unless I'm doing something wrong. Looks like a great tool, look forward to using it!
blade/blade.go
26 region := endpoints.UsEast1RegionID
27 awsConfig := aws.Config{Region: ®ion}
seems the region is hardcoded to us-east-1
Yep, so it is. Sorry for not looking deeper yesterday. Let me fix that up and cut a new release.
awesome!
So sorry for the delay, my wife and I just had a baby girl Friday night so we've been exhausted and busy!
Firstly, congratulations! Secondly, don’t sweat it, you’ve provided this for free and it looks awesome, you don’t owe us anything!
Congrats Tyler :)
Took a little break, haha! 😄I was able to have it read from the default profile pretty easily.
I still need to add overrides for region + profile so you can more easily select them via -r and -p but the v0.1.4 release should work if you have ~/.aws/config profile default to the region you want. Let me know if that works for you all right now in a pinch.
Tested it with ~/.aws/credentials set to [profilename] aws_access_key_id = 123 aws_secret_access_key = 123 region = eu-west-1
and it works perfectly. Thanks again for the quick fix!
Support for overriding default profile and the current profile's region will be released as part of v0.1.5 in a couple minutes... hold tight 🚢 :shipit:
Awesome tool! It looks like there's no region support, is that correct?