From 723a574ef8d05e328d79697946279ff0d197ee9b Mon Sep 17 00:00:00 2001 From: Clark Boylan Date: Thu, 12 Nov 2015 09:59:22 -0800 Subject: [PATCH] Allow CORS against elasticsearch API Since we do fine grained access control to the API via a proxy that limits what requests can be made from anywhere go ahead and allow CORS requests from anywhere as they won't be able to write data anyways. This is useful so that you can test a new version of $tool hosted locally against the actual cluster or for admins to run admin tools hosted locally against the cluster. Change-Id: I774d0ad0b246315794ab387acc39c41c7cfac3cd Depends-On: I0aa8d5167c770c1024b7596da582d6cc089b1b47 --- modules/openstack_project/manifests/elasticsearch_node.pp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/modules/openstack_project/manifests/elasticsearch_node.pp b/modules/openstack_project/manifests/elasticsearch_node.pp index e83d4238e2..58811056dd 100644 --- a/modules/openstack_project/manifests/elasticsearch_node.pp +++ b/modules/openstack_project/manifests/elasticsearch_node.pp @@ -32,6 +32,8 @@ class openstack_project::elasticsearch_node ( 'discovery.zen.minimum_master_nodes' => '4', 'discovery.zen.ping.multicast.enabled' => false, 'discovery.zen.ping.unicast.hosts' => $discover_nodes, + 'http.cors.enabled' => true, + 'http.cors.allow-origin' => "'*'", # lint:ignore:double_quoted_strings }, heap_size => $heap_size, version => '1.7.3',