mirror of
https://github.com/aljazceru/ansible-elasticsearch.git
synced 2025-12-17 17:14:20 +01:00
Shield config tests + prevent use of xpack in version < 2.0
This commit is contained in:
@@ -160,5 +160,12 @@ shared_examples 'xpack::init' do |es_version|
|
||||
end
|
||||
|
||||
#Test contents of Elasticsearch.yml file
|
||||
describe file('/etc/elasticsearch/shield_node/elasticsearch.yml') do
|
||||
it { should contain 'shield.authc.realms.file1.order: 0' }
|
||||
it { should contain 'shield.authc.realms.file1.type: file' }
|
||||
it { should contain 'shield.authc.realms.native1.order: 1' }
|
||||
it { should contain 'shield.authc.realms.native1.type: native' }
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
|
||||
@@ -2,7 +2,9 @@
|
||||
- name: Elasticsearch Xpack tests
|
||||
hosts: localhost
|
||||
roles:
|
||||
- { role: elasticsearch, es_config: { "http.port": 9200, "transport.tcp.port":9300, discovery.zen.ping.unicast.hosts: "localhost:9300" }, es_instance_name: "shield_node" }
|
||||
- { role: elasticsearch, es_config: { "http.port": 9200, "transport.tcp.port":9300, discovery.zen.ping.unicast.hosts: "localhost:9300",
|
||||
"shield.authc.realms.file1.type": "file","shield.authc.realms.file1.order": 0, "shield.authc.realms.native1.type": "native","shield.authc.realms.native1.order": 1 },
|
||||
es_instance_name: "shield_node" }
|
||||
vars:
|
||||
es_templates: true
|
||||
es_enable_xpack: true
|
||||
|
||||
Reference in New Issue
Block a user