Commit ff01ce0c authored by Thomas Schneider's avatar Thomas Schneider
Browse files

redis-server: Allow configuration

parent f12ad8c2
Pipeline #2770 passed with stage
in 26 seconds
---
redis_bind: "127.0.0.1 ::1"
# Set to "0" to disable TCP
redis_port: "6379"
redis_unixsocket: false
redis_unixsocketperm: "770"
---
- name: Reload systemd
systemd:
daemon-reload: true
- name: Restart redis-server
systemd:
unit: redis-server.service
state: restarted
---
- name: ensure we have redis installed
- name: Install redis-server
apt:
name: redis-server
state: present
- name: Create systemd unit override directory
file:
path: /etc/systemd/system/redis-server.service.d
state: directory
- name: Configure redis-server systemd options
copy:
src: override.conf
dest: /etc/systemd/system/redis-server.service.d/override.conf
notify:
- Reload systemd
- Restart redis-server
- name: Configure redis-server
template:
src: redis.conf.j2
dest: /etc/redis/redis.conf
owner: redis
group: redis
mode: '0640'
notify:
- Restart redis-server
- name: Enable and start redis-server
systemd:
unit: redis-server.service
enabled: true
state: started
This diff is collapsed.
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment