-
Notifications
You must be signed in to change notification settings - Fork 52
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
override default server variable #36
Comments
Hi @adriensaladin, I'm not sure I understand yet what the problem is. Usually overriding It may also be worth reviewing the relevant ansible documentation on variables. |
Hi @jaytaylor, From what I understand it is not easy to override a single key of an Ansible dictionary.
will override So the example using |
Hi guys, i think this pull request will solve this problem (I was experiencing it too, hence I created the PR) |
Hi,
I had to override server.advertised_listeners, which is defined in the default role variables, and it was quite a difficult task.
I asked a coworker which knows Ansible much better than I and the best method we found so far is to use
pre_tasks
as bellow:The thing is we either need to completely redefine the
server
dict in the ansible play, or change the Ansible merge strategy in ansible.cfg (which is generally a bad idea) or use thisset_fact
trick.Are you aware of a better method to redefine those variables ? If not, would you like to add an example in the role documentation?
Cheers,
The text was updated successfully, but these errors were encountered: