Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Shared credentials file is not reloaded when credentials expire #154

Open
luisgerhorst opened this issue Jul 31, 2023 · 3 comments
Open

Comments

@luisgerhorst
Copy link
Contributor

luisgerhorst commented Jul 31, 2023

As mentioned by https://github.com/aws/aws-sdk-go/blob/b75b2a7b3cb40ece5774ed07dde44903481a2d4d/example/aws/request/customRetryer/custom_retryer.go#L31, the default credentials search path does not reload the file even if it only contains temporary credentials. This is because it creates static credentials from the values read and does not use the provider: https://sourcegraph.com/github.com/aws/aws-sdk-go/-/blob/aws/session/credentials.go?L116

I'm working on a PR to fix that.

Note: Also, just using the provider is not sufficient. One also has to call Credentials.Expire() to trigger the reload (which does not happen automatically even if the refresh time is in the credentials file).

@luisgerhorst
Copy link
Contributor Author

There's a cross-sdk ticket for this feature to be added to the SDK: aws/aws-cli#9034

@kid1412621
Copy link

kid1412621 commented Aug 11, 2023

having the same issue.
using this to bypass temporarily

    healthcheck:
      test: ["CMD-SHELL", "wget -q --spider localhost:8080 || exit 1"]
    restart: on-failure

@luisgerhorst
Copy link
Contributor Author

I now also worked around this by restarting the proxy every hour using systemd.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants