Answer the question
In order to leave comments, you need to log in
Is it possible to override a variable during playbook startup?
Hello everyone,
if in the vars subdirectory, from the directory where the playbooks are stored in the main.yml file, I set the phpversion variable: "7.0"
can I override it during the start of the playbook? For example ansible-playbook -e "phpversion=7.1" or will the version set in main.yml still be used?
Answer the question
In order to leave comments, you need to log in
Here is the order of precedence from lowest to highest (the last variables listed win in terms of priority):
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question