geerlingguy / ansible-role-redis

Ansible Role - Redis
https://galaxy.ansible.com/geerlingguy/redis/
MIT License
254 stars 197 forks source link

Added sudo true to task: Ensure redis is running and enabled on boot #7

Closed iAugur closed 9 years ago

iAugur commented 9 years ago

Since updating to 1.9 I have been getting msg: touch: cannot touch ‘/var/run/redis/redis-server.pid’: Permission denied As the sudo is not passed in from the playbook (known Ansible issues - fixed in dev I believe). So I have forked this to update for my use - let me know if you think this is valid

geerlingguy commented 9 years ago

I typically run the entire role as sudo (or as root), so the playbook controls the user access level. Often the rest of the redis setup also needs sudo, so it's easiest to simply do - { name: geerlingguy.redis, sudo: yes } when including the role if you don't want the entire playbook to run with sudo.