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

Support multi urls and basicauth for es #3567

Open
hyphennn opened this issue Jul 17, 2024 · 5 comments
Open

Support multi urls and basicauth for es #3567

hyphennn opened this issue Jul 17, 2024 · 5 comments

Comments

@hyphennn
Copy link

hyphennn commented Jul 17, 2024

Hi there.

Suppose that now I have a elastic cluster, which I do not want or I just can not enable sniffer, but still has several nodes to use. I configure the --storage_driver_es_host flag. Here comes the question: --storage_driver_es_host can conly accept one node, as the olivere/elastic.v2 supports multi nodes.

// cmd/internal/storage/elasticsearch/elasticsearch.go L131
        client, err := elastic.NewClient(
		elastic.SetHealthcheck(true),
		elastic.SetSniff(enableSniffer),
		elastic.SetHealthcheckInterval(30*time.Second),
		elastic.SetURL(elasticHost),
	)

I think it is not only helpful but also easy to change the 'elasticHost' variable into a multi nodes format, such as:

--storage_driver_es_host='1.1.1.1:5000,2.2.2.2:5000,3.3.3.3:5000'

Also, basic auth is not supported while I think it should be.

-storage_driver_es_username="xxx"
-storage_driver_es_password="xxx"

I do hope these can be supported in cAdvisor.

@hyphennn
Copy link
Author

I've submitted a PR #3568 for this issue. I do hope it will work. Thanks a lot.

@hyphennn hyphennn changed the title Support Multi URLs for ES Support multi urls for es Jul 17, 2024
@hyphennn hyphennn changed the title Support multi urls for es Support multi urls and basicauth for es Jul 17, 2024
@hyphennn
Copy link
Author

Hello? Is there anybody still maintaining this project? Or any new version/feature will be released?

@JonathanMbt
Copy link

I would be interested in that feature as well !

@iwankgb
Copy link
Collaborator

iwankgb commented Sep 7, 2024

Hello? Is there anybody still maintaining this project?

Mostly volunteers working in their spare time.

@hyphennn
Copy link
Author

Hello? Is there anybody still maintaining this project?

Mostly volunteers working in their spare time.

That's definitely right, sry for my impatience.

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

3 participants