redis.yml 495 B

123456789101112131415161718192021222324
  1. ---
  2. # tasks/Debian/redis.yml: Deploy redis
  3. # Specific to Debian
  4. - include_vars: "{{ ansible_distribution }}.yml"
  5. tags: redis
  6. - name: Ensure redis is installed
  7. tags: redis
  8. apt:
  9. name: "{{ redis_pkg_name }}"
  10. state: "{{ redis_pkg_state }}"
  11. update_cache: true
  12. - name: Ensure redis binds to accessible IP
  13. tags: redis
  14. lineinfile:
  15. dest: /etc/redis/redis.conf
  16. regexp: '^bind'
  17. line: 'bind 0.0.0.0'
  18. notify: restart redis service
  19. - meta: flush_handlers
  20. tags: redis