CompTIA Linux+ XK0-006 (V8) Practice Question

While troubleshooting an unexpected configuration change, you discover that the variable app_version is defined in four different places. The playbook is executed with:

ansible-playbook site.yml -e "app_version=3.4.9"

No other definitions of the variable exist. The same variable is also set in group_vars/webservers.yml, inside host-specific variables in the inventory file, and in the role's defaults/main.yml. Which definition will Ansible apply during the run?

  • The value set for the host in the inventory file.

  • The default value in the role's defaults/main.yml file.

  • The value defined in group_vars/webservers.yml.

  • The value supplied with --extra-vars at runtime (3.4.9).

CompTIA Linux+ XK0-006 (V8)
Automation, Orchestration, and Scripting
Your Score:
Settings & Objectives
Random Mixed
Questions are selected randomly from all chosen topics, with a preference for those you haven’t seen before. You may see several questions from the same objective or domain in a row.
Rotate by Objective
Questions cycle through each objective or domain in turn, helping you avoid long streaks of questions from the same area. You may see some repeat questions, but the distribution will be more balanced across topics.

Check or uncheck an objective to set which questions you will receive.

Bash, the Crucial Exams Chat Bot
AI Bot