redis-stat
redis-stat copied to clipboard
Consider supporting custom ssl certificates configuration for elasticsearch client
It would be really great to support the transport_options
hash parameter for the Elasticsearch::Client initialization, to specify a custom SSL cert for https://
urls.
See this section of the Elasticsearch README for example usage.
Not sure what your preferred method of passing this configuration data into the redis-stat
server is, @junegunn.
It feels like adding another CLI flag for this option would be clunky, and you don't have any precedent for a config file. What are your thoughts here?
I'd be happy to help with a PR, or could fork if you think this change isn't generally useful.
Thanks for such a great tool!
Hi, actually adding support for ElasticSearch was not my idea, and due to my lack of good understanding of ES, the feature has not been systematically tested and I'm not really sure if the current implementation follows the best practice. So if you have any feedback on the part, feel free to let me know.
So anyway, looks like we have three options:
- Another CLI flag
- We're current packing stuff into a single
--es
flag, adding another doesn't really feel nice - Short-sighted if we're going to have to add more of such flags
- We're current packing stuff into a single
- Environment variable (e.g.
ES_CA_PATH
)- Easier to implement, and to extend in the future
- It's the first env var ever used, so it's inconsistent
- External config file
- The ultimate solution
- Most likely overkill
Of those options, an ENV var gets my vote!