• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

Elastic Search Default XF HTTP Use - How to Change?

Anthony Parsons

Well-known member
#1
By default, entering a location in the ES option field makes it http:// regardless whether using port 443 to run ES securely...

How can I change it so it default uses https:// without having to redirect http to https at the ES server?
 

Mouth

Well-known member
#2
How can I change it so it default uses https:// without having to redirect http to https at the ES server?
Looking at library/XenES/Api.php it looks like Enhanced Search is hard coded to http only, with no support for https.
Probably an enhancement request for https://xenforo.com/community/forums/enhanced-search-suggestions.55/

PHP:
                        $esServerOption = XenForo_Application::get('options')->elasticSearchServer;
                        if ($esServerOption)
                        {
                                $server = "http://$esServerOption[host]:$esServerOption[port]/";
                        }
                        else
                        {
                                $server = 'http://127.0.0.1:9200/';
                        }
 
Last edited:

Anthony Parsons

Well-known member
#3
Thanks @Mouth. Yer, I went looking and couldn't find anything either.

With NGINX to secure ES, it allows https to stream all traffic and thus ES is proxied internally... let alone using Shield by Elastic Co, if going the paid route.

SSL would be nice to have as an option.