Albirew/nyaa-pantsu
Archivé
1
0
Bifurcation 0

Add playbook to create the index

Cette révision appartient à :
tomleb 2017-05-17 16:25:47 -04:00
Parent 94af9997e0
révision ee0dc13faf

Voir le fichier

@ -0,0 +1,18 @@
- name: Create elasticsearch index
hosts: dbs
roles:
- common
- elasticsearch
tasks:
- name: Read configuration file
shell: cat "{{ nyaapantsu_directory }}/elasticsearch_settings.yml"
register: config
- name: Configure elasticsearch index
uri:
headers:
Content-Type: application/yaml
url: "http://localhost:9200/{{ nyaapantsu_elasticsearch_index }}"
method: PUT
body: "{{ config.stdout }}"