Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use apt_repository update_cache parameter #1

Merged
merged 1 commit into from Mar 1, 2015
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
9 changes: 1 addition & 8 deletions tasks/setup-Debian.yml
Expand Up @@ -8,14 +8,7 @@
apt_repository:
repo: 'deb http://packages.elasticsearch.org/elasticsearch/1.1/debian stable main'
state: present

- name: Check if Elasticsearch is already installed.
stat: path=/etc/init.d/elasticsearch
register: elasticsearch_installed

- name: Update apt cache if repository just added.
apt: update_cache=yes
when: elasticsearch_installed.stat.exists == false
update_cache: yes

- name: Install Elasticsearch.
apt: pkg=elasticsearch state=present