Pseudocode:
If env is de, set variable name to hello else if env is prod, set variable name to bye.
I tried https://serverfault.com/questions/715769/ansible-change-default-value-according-to-a-condition
- name: setting variable
set_fact: name="hello"
when: "{{ env }}" == "de"
- name: setting variable
set_fact: name="bye"
when: "{{ env }}" == "prod"
ERROR! The default/main.yml file for role 'trial' must contain a dictionary of variables