Add helper script to call assume role (#12978)

This commit is contained in:
Aditya Manthramurthy
2021-08-17 01:46:59 -07:00
committed by GitHub
parent ad928f0078
commit 9b7d593e28
2 changed files with 158 additions and 1 deletions

View File

@@ -81,7 +81,7 @@ $ minio server ~/test
Create new users following the multi-user guide [here](https://docs.min.io/docs/minio-multi-user-quickstart-guide.html)
Testing with an example
### Testing an example with awscli tool
> Use the same username and password created in the previous steps.
```
@@ -108,6 +108,20 @@ $ aws --profile foobar --endpoint-url http://localhost:9000 sts assume-role --po
}
```
### Testing an example with `assume-role.go`
The included program in this directory can also be used for testing:
``` shell
$ go run assume-role.go -u foobar -p foo12345 -d
Only displaying credentials:
AccessKeyID: 27YDRYEM0S9B44AJJX9X
SecretAccessKey: LHPdHeaLiYk+pDZ3hgN3sdwXpJC2qbhBfZ8ii9Z3
SessionToken: eyJhbGciOiJIUzUxMiIsInR5cCI6IkpXVCJ9.eyJhY2Nlc3NLZXkiOiIyN1lEUllFTTBTOUI0NEFKSlg5WCIsImV4cCI6MzYwMDAwMDAwMDAwMCwicG9saWN5IjoiY29uc29sZUFkbWluIn0.2d9t0UOm1jQmwe31_5CyN63f6CL-fhqZSO-XhZIp-NH5QteWv9oSMjIrcNWzMgNDblrUfAZ0JSs8a1ciLQF9Ww
```
## Explore Further
- [MinIO Admin Complete Guide](https://docs.min.io/docs/minio-admin-complete-guide.html)
- [The MinIO documentation website](https://docs.min.io)