redis.yml 551 B

123456789101112131415161718192021222324252627
  1. ---
  2. # tasks/Amazon/redis.yml: Deploy redis
  3. # Specific to Amazon Linux AMI
  4. - include_vars: "{{ ansible_distribution }}.yml"
  5. tags: redis
  6. - name: Install EPEL repo
  7. tags: redis
  8. yum:
  9. name: "{{ epel_repo_rpm }}"
  10. state: present
  11. when: enable_epel_repo
  12. - name: Ensure redis is installed
  13. tags: redis
  14. yum:
  15. name: "{{ redis_pkg_name }}"
  16. state: "{{ redis_pkg_state }}"
  17. enablerepo: epel
  18. - name: Ensure redis binds to accessible IP
  19. tags: redis
  20. lineinfile:
  21. dest: /etc/redis.conf
  22. regexp: '^bind'
  23. line: 'bind 0.0.0.0'