▶ MCQ Portal
Home
Medical
Neet-Ug
4
Ssc-Cgl
General_Awareness
5
Devops
Ansible
10
Aws
5
Azure
10
Docker
5
Jenkins
5
Kubernetes
5
Terraform
10
⚑ Feedback
Home
ansible
Exam2
Exam2
devops / ansible
• 5 questions
Question 1 of 5
What is an Ansible Role?
A.
A type of inventory host
B.
A structured way to organize tasks, variables, and files for reuse
C.
A privilege level for remote users
D.
A connection plugin
Question 2 of 5
Which directory inside an Ansible role contains the main task list?
A.
tasks/
B.
handlers/
C.
meta/
D.
defaults/
Question 3 of 5
Which command creates a new role scaffold?
A.
ansible role create myrole
B.
ansible-galaxy role init myrole
C.
ansible-role new myrole
D.
ansible init role myrole
Question 4 of 5
Variables defined in `defaults/main.yml` of a role have which priority?
A.
Highest priority
B.
Medium priority
C.
Lowest priority, easily overridden
D.
They cannot be overridden
Question 5 of 5
How do you include a role in a playbook?
A.
import: myrole
B.
use_role: myrole
C.
roles: [ myrole ]
D.
include_role name=myrole
← Back
Submit Answers ✓