Skip to content

Add config for sts_credentials_region #65

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

Merged
merged 3 commits into from
Jun 9, 2020

Conversation

csolidum
Copy link

@csolidum csolidum commented Jun 3, 2020

This is useful for fluentd deployments running in a different region
than their elasticsearch cluster and want to take advantage of local sts
endpoints

This is useful for fluentd deployments running in a different region
than their elasticsearch cluster and want to take advantage of local sts
endpoints
@@ -20,6 +20,7 @@ class AwsElasticsearchServiceOutput < ElasticsearchOutput
config_param :ecs_container_credentials_relative_uri, :string, :default => nil #Set with AWS_CONTAINER_CREDENTIALS_RELATIVE_URI environment variable value
config_param :assume_role_session_name, :string, :default => "fluentd"
config_param :assume_role_web_identity_token_file, :string, :default => nil
config_param :sts_credentials_region, :string, :default => ""
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Refactored the code for better testability, but held off on updating tests since it looks like tests are broken even on master.

Copy link

@prudhvi prudhvi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Comment on lines 120 to 121


Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you remove these newlines?
In Ruby style, using one newline between the functions is better.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removed

@@ -20,6 +20,7 @@ class AwsElasticsearchServiceOutput < ElasticsearchOutput
config_param :ecs_container_credentials_relative_uri, :string, :default => nil #Set with AWS_CONTAINER_CREDENTIALS_RELATIVE_URI environment variable value
config_param :assume_role_session_name, :string, :default => "fluentd"
config_param :assume_role_web_identity_token_file, :string, :default => nil
config_param :sts_credentials_region, :string, :default => nil
Copy link
Collaborator

@cosmo0920 cosmo0920 Jun 9, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you add this parameter in README documentation?
https://github.com/atomita/fluent-plugin-aws-elasticsearch-service/blob/master/README.md

Only existing in plugin code, users don't get noticed this.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated an example in the README to include this config option.

Copy link
Collaborator

@cosmo0920 cosmo0920 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. Thank you for your work! 👍

@cosmo0920 cosmo0920 merged commit 4312392 into atomita:master Jun 9, 2020
@cosmo0920
Copy link
Collaborator

@atomita Could you release the new version of this plugin?

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

Successfully merging this pull request may close these issues.

3 participants