Adding ubuntu directions to elasti role

This commit is contained in:
James Tombleson 2019-04-25 15:59:42 -07:00
parent 79b7a915ac
commit 3721747f01
2 changed files with 31 additions and 19 deletions

View File

@ -4,25 +4,29 @@
- name: Test role - name: Test role
debug: var=cluster_name debug: var=cluster_name
- name: Install Elastic GPG Key - name: Install Elastic Repo
become: true include: install-repo.yml
apt_key: when: ansible_distribution == "Ubuntu"
url: "https://artifacts.elastic.co/GPG-KEY-elasticsearch"
state: present
id: 46095ACC8548582C1A2699A9D27D666CD88E42B4
- name: Install apt-transport-https #- name: Install Elastic GPG Key
become: true #become: true
apt: #apt_key:
name: apt-transport-https #url: "https://artifacts.elastic.co/GPG-KEY-elasticsearch"
#state: present
#id: 46095ACC8548582C1A2699A9D27D666CD88E42B4
- name: Add Elastic Repo #- name: Install apt-transport-https
become: true # become: true
copy: #apt:
dest: '/etc/apt/sources.list.d/elastic-7.x.list' #name: apt-transport-https
content: "deb https://artifacts.elastic.co/packages/7.x/apt stable main"
- name: Update Packages #- name: Add Elastic Repo
become: true # become: true
apt: # copy:
update_cache: true # dest: '/etc/apt/sources.list.d/elastic-7.x.list'
# content: "deb https://artifacts.elastic.co/packages/7.x/apt stable main"
#- name: Update Packages
#become: true
# apt:
# update_cache: true

View File

@ -0,0 +1,8 @@
- name: Install ElasticSearch from apt
become: true
apt:
name: elasticsearch
- name: