Commit caa6fca9 authored by Daniel Berman's avatar Daniel Berman Committed by GitHub
Browse files

Create main.yml

parent 6ecd2714
---
#
# Installing Elasticsearch
#
# Add apt-key
- name: Add apt-key
apt_key:
url: "https://artifacts.elastic.co/GPG-KEY-elasticsearch"
state: present
# Add the Elasticsearch APT-repository
- name: Adding Elasticsearch APT repository
apt_repository:
repo: deb https://artifacts.elastic.co/packages/5.x/apt stable main
state: present
# Install Elasticsearch
- name: Update repos cache, install Elasticsearch
apt:
name: elasticsearch
update_cache: yes
# Update Elasticsearch config file to allow remote connections
- name: Updating config file to allow outside access
lineinfile:
destfile: /etc/elasticsearch/elasticsearch.yml
regexp: 'network.host:'
line: 'network.host: 0.0.0.0'
# Start Elasticsearch
- name: Starting Elasticsearch
service:
name: elasticsearch
state: started
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment