diff options
author | Christian Pointner <equinox@spreadspace.org> | 2024-07-15 23:42:17 +0200 |
---|---|---|
committer | Christian Pointner <equinox@spreadspace.org> | 2024-07-15 23:42:17 +0200 |
commit | 062c0cc41a38b003e614dc2c49cd22da304c838f (patch) | |
tree | 46ccbeddf69dd5fa45304e2e5e6d7e3b7a0622cd /roles/redis/server/tasks/main.yml | |
parent | add minimalistc redis-server role (diff) |
redis-server: add configurable storage volume
Diffstat (limited to 'roles/redis/server/tasks/main.yml')
-rw-r--r-- | roles/redis/server/tasks/main.yml | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/roles/redis/server/tasks/main.yml b/roles/redis/server/tasks/main.yml index 8114bced..8cd44ee5 100644 --- a/roles/redis/server/tasks/main.yml +++ b/roles/redis/server/tasks/main.yml @@ -1,10 +1,26 @@ --- +- name: prepare storage volume for /var/lib/redis + when: redis_server_storage is defined + vars: + storage_volume: "{{ redis_server_storage | combine({'dest': '/var/lib/redis'}) }}" + include_role: + name: "storage/{{ redis_server_storage.type }}/volume" + - name: install redis-server packages apt: name: - redis-server state: present +- name: make sure redis can write storage directory + file: + path: /var/lib/redis + state: directory + owner: redis + group: redis + mode: 0750 + notify: restart redis-server + - name: configure legacy authentication password when: redis_server_legacy_auth_password is defined lineinfile: |