Skip to content

Cannot install redis and redis-sentinel on the same host? #256

@drsharp

Description

@drsharp

I noted that tasks/main.yml has this:

- include: server.yml
  when: not redis_sentinel
  tags:
    - config

- include: sentinel.yml
  when: redis_sentinel
  tags:
    - config

Because of the when conditionals, it appears that it will only run one or the other. Thus, depending on the true/false of redis_sentinel variable, it will only install redis server or the sentinel.

However, I need to have both for my configuration.

Could a second variable be used instead? maybe something like this:

- include: server.yml
  when: redis_server
  tags:
    - config

- include: sentinel.yml
  when: redis_sentinel
  tags:
    - config

That way the two variables: redis_server and redis_sentinel could be set independently.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions