Open NicholasFiorentini opened 1 year ago
Just to double-check, I tried this:
cat(file=stderr(), paste0("Key: ", aws_credentials$key, "\n"))
cat(file=stderr(), paste0("Secret: ", aws_credentials$secret, "\n"))
cat(file=stderr(), paste0("Token: ", aws_credentials$session_token, "\n"))
cat(file=stderr(), paste0("Region: ", aws_credentials$region, "\n"))
bucket_access <- aws.s3::bucket_exists(
"my_bucket",
key=aws_credentials$key,
secret=aws_credentials$secret,
session_token=aws_credentials$session_token,
region=aws_credentials$region)
Output:
Key: ***
Secret: ***
Token: ***
Region: us-west-2
Client error: (403) Forbidden
Does aws.s3
support STS tokens?
I'm facing the same issue. Any workarounds?
Ultimately, I moved to a different library to overcome this limitation.
The workaround would be using an AWS API key, but I would avoid it.
Please specify whether your issue is about:
I'm running my code from rshiny server. The session token is provided using https://docs.aws.amazon.com/eks/latest/userguide/pod-configuration.html.
The
bucket_exists
call fails with the error:Further details
The output of
credentials
shows the correct key id, secret, toke, and region.The attached token is valid: running
awscli
from the same pod I can access the bucket without error.Output of sessionInfo()