2019-04-22 15:01:56 -07:00
|
|
|
# This will work on a new install.
|
|
|
|
|
|
|
|
# Allow 9200 so we can access it over the network
|
|
|
|
- name: Allow port 9200 though UFW
|
2019-04-23 12:21:00 -07:00
|
|
|
become: true
|
|
|
|
ufw:
|
|
|
|
rule: allow
|
|
|
|
port: 9200
|
|
|
|
#name: ElasticSearch
|
|
|
|
|
|
|
|
- name: Allow port 9300 though UFW
|
|
|
|
become: true
|
|
|
|
ufw:
|
|
|
|
rule: allow
|
|
|
|
port: 9300
|
2019-04-22 15:01:56 -07:00
|
|
|
|
|
|
|
- name: Service reload daemon
|
2019-04-23 12:21:00 -07:00
|
|
|
become: true
|
|
|
|
systemd:
|
|
|
|
daemon_reload: yes
|
2019-04-22 15:01:56 -07:00
|
|
|
|
|
|
|
- name: systemd - enable ElasticSearch on startup
|
2019-04-23 12:21:00 -07:00
|
|
|
become: true
|
|
|
|
systemd:
|
|
|
|
name: elasticsearch
|
|
|
|
enabled: yes
|
2019-04-22 15:01:56 -07:00
|
|
|
|
|
|
|
- name: systemd - restart ElasticSearch service
|
2019-04-23 12:21:00 -07:00
|
|
|
become: true
|
|
|
|
systemd:
|
|
|
|
name: elasticsearch
|
|
|
|
state: restarted
|