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

0.4.x - fix(config): check if AWS key and secret are not empty #66

Merged
merged 5 commits into from
Feb 7, 2023

Conversation

pflorek
Copy link
Contributor

@pflorek pflorek commented Nov 18, 2022

if using AWS_ACCESS_KEY_ID='' or AWS_SECRET_ACCESS_KEY='' an exception will be thrown

Error executing "PutEvents" on "https://events.us-east-1.amazonaws.com"; AWS HTTP error: Client error: `POST https://events.us-east-1.amazonaws.com` resulted in a `400 Bad Request` response:
{"__type":"UnrecognizedClientException","message":"The security token included in the request is invalid."}

if using `AWS_ACCESS_KEY_ID=''` or `AWS_SECRET_ACCESS_KEY=''` an exception will be thrown

```
Error executing "PutEvents" on "https://events.us-east-1.amazonaws.com"; AWS HTTP error: Client error: `POST https://events.us-east-1.amazonaws.com` resulted in a `400 Bad Request` response:
{"__type":"UnrecognizedClientException","message":"The security token included in the request is invalid."}
```
@Grummfy
Copy link

Grummfy commented Jan 12, 2023

note : it's only required if you provide them, if you are in an aws instance (ec2, ecs, kubernetes, ...) it will be provided not by the configuration, but by the instance

@pflorek
Copy link
Contributor Author

pflorek commented Feb 7, 2023

note : it's only required if you provide them, if you are in an aws instance (ec2, ecs, kubernetes, ...) it will be provided not by the configuration, but by the instance

Yes, I prefer to use the instance profile, task role or service account instead of access keys and let the credential chain resolve it.

Just got from the infrastructure an empty string instead a null and then got that error. Would be really nice to have a not empty check instead a not null.

@pflorek
Copy link
Contributor Author

pflorek commented Feb 7, 2023

@clemblanco

@clemblanco
Copy link
Contributor

Thanks @pflorek will have a look! 👍

@pflorek
Copy link
Contributor Author

pflorek commented Feb 7, 2023

Thanks @pflorek will have a look! 👍

@clemblanco thanks for this nice library, works like a charm

@clemblanco clemblanco changed the title fix: check if aws key and secret are not empty 0.4.x - fix(config): check if AWS key and secret are not empty Feb 7, 2023
@clemblanco clemblanco merged commit 8cb57f4 into Pod-Point:main Feb 7, 2023
@pflorek pflorek deleted the fix/check-empty-aws-credentials branch February 7, 2023 15:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants