diff --git a/roles/redis/defaults/main.yml b/roles/redis/defaults/main.yml index 4050cc6..2108362 100644 --- a/roles/redis/defaults/main.yml +++ b/roles/redis/defaults/main.yml @@ -27,5 +27,4 @@ redis_docker_ports: [ "6379:6379" ] redis_docker_networks: ~ redis_docker_purge_networks: false redis_docker_volumes: - - "{{ redis_data_dir }}:/data" - - "{{ redis_config_file }}:{{ redis_docker_configpath }}" + diff --git a/roles/redis/vars/main.yml b/roles/redis/vars/main.yml index 802c61c..5bd7db0 100644 --- a/roles/redis/vars/main.yml +++ b/roles/redis/vars/main.yml @@ -1,5 +1,10 @@ --- +redis_docker_volumes_base: + - "{{ redis_data_dir }}:/data" + - "{{ redis_config_file }}:{{ redis_docker_configpath }}" +redis_docker_volumes: "{{ redis_docker_volumes_base + redis_docker_extra_volumes|default([]) }}" + redis_docker_labels_base: version: "{{ redis_version }}" redis_docker_labels_complete: "{{ redis_docker_labels_base | combine(redis_docker_labels) }}"