Possible to place ElasticSearch.yml outside of Tomcat WAR file?

I'm using the Java Client API (for version 19.8) and would like to have a custom elasticsearch.yml file outside of the WAR file when running inside Tomcat. The specific environment that I'm running in is CentOS running inside Amazon using ElasticBeanstalk.

I've tried placing the file in the /opt/tomcat7 and /opt/tomcat7/config directories and it doesn't seem to work. Is there someplace else I can place it or a config setting I can add to make this work?

(When I run with Jetty on my Windows development box, I can place it in the config directory under my current working directory and things work fine. When running inside AWS, it also works if I place it in the WAR file in the WEB-INF/classes/config directory.)

I think you can deal with it using settings when you start your ES client.

Have a look here:
https://github.com/dadoonet/spring-elasticsearch/blob/master/src/main/java/fr/pilato/spring/elasticsearch/ElasticsearchTransportClientFactoryBean.java#L85

HTH

David :wink:
Twitter : @dadoonet / @elasticsearchfr / @scrutmydocs

Le 30 août 2012 à 02:58, John Bartak john.bartak@autodesk.com a écrit :

I'm using the Java Client API (for version 19.8) and would like to have a
custom elasticsearch.yml file outside of the WAR file when running inside
Tomcat. The specific environment that I'm running in is CentOS running
inside Amazon using ElasticBeanstalk.

I've tried placing the file in the /opt/tomcat7 and /opt/tomcat7/config
directories and it doesn't seem to work. Is there someplace else I can
place it or a config setting I can add to make this work?

(When I run with Jetty on my Windows development box, I can place it in the
config directory under my current working directory and things work fine.
When running inside AWS, it also works if I place it in the WAR file in the
WEB-INF/classes/config directory.)

--
View this message in context: http://elasticsearch-users.115913.n3.nabble.com/Possible-to-place-ElasticSearch-yml-outside-of-Tomcat-WAR-file-tp4022278.html
Sent from the Elasticsearch Users mailing list archive at Nabble.com.

--

--