Where to place the CORS file


I am following the elasticsearch-angular-example by Spence Spalger. The text says to place the CORS file near the config file. But I do not see a config file, just a config directory with 2 YAML files. So where does the CORS file go? Asa YAML file in the config directory?

Thanks for the help..

enabled: true
allow-origin: /https?://localhost(:[0-9]+)?/

(Pemontto) #2

The settings go in your elasticsearch.yml file. See the CORS settings in the documentation


Thank you.. The elasticsearch.yaml file as downloaded only contains comments. Can I delete all and those and insert the CORS text?

(David Pilato) #4

Yes you can.

But often, you want to define cluster.name at least.


Thanks David .. I will read the documentation and define the cluster name there as well.


Thank you .. this worked .. you knew it would ! The example ran fine when I
started elasticsearch.bat on my local drive

Another question. .. I am a real newbie at web development. I deploy an app
to firebase. How do I get firebase to run elasticsearch?



(system) #7