Where is the first place Ansible checks for a role definition?
A. ${PWD}/rolesWhich are of the following are valid uses of a role's meta directory? (Choose all that apply.)
A. Setting variable values for use within a role.Create a role called sample-apache in /home/sandy/ansible/roles that enables and starts httpd, enables and starts the firewall and allows the webserver service. Create a templatecalled index.html.j2 which creates and serves a message from /var/www/html/index.html Whenever the content of the file changes, restart the webserver service.
Welcome to [FQDN] on [IP]
Replace the FQDN with the fully qualified domain name and IP with theip address of the node using ansible facts. Lastly, create a playbook in /home/sandy/ansible/ called apache.yml and use the role to serve the index file on webserver hosts.
Correct Answer. Check the answer in explanationCreate a file called packages.yml in /home/sandy/ansible to install somepackages for the following hosts. On dev, prod and webservers install packages httpd, mod_ssl, and mariadb. On dev only install the development tools package. Also, on dev host update all the packages to the latest.
Correct Answer. Check the answer in explanationCreate a file called requirements.yml /home/sandy/ansible/roles in a file called role.yml in /home/sandy/ansible/. The haproxy-role should be used on the proxy host. And when you curl http://node3.example.com it should display "Welcome tonode4.example.com" and when you curl again "Welcome tonode5.example.com"The php-role should be used on the prod host.
Correct Answer. Check the answer in explanationCreate a role called sample-apache and store it in /home/bob/ansible/roles. The role should
satisfy the following requirements:
*In the role, install and enable httpd. Also enable the firewall to allow http. Also run the template
*index.html.j2 and make sure this runs Create a template index.html.j2 that displays "Welcome to the server HOSTNAME"
In a play called apache.yml in /home/bob/ansible/ run the sample-apache role.
Correct Answer. Check the answer in explanationIs it possible to specify multiple inventory files at once?
A. Yes, you specify your inventory as a directory containing valid inventory files.State whether the following statement is true or false.
The command ansible-galaxy init won't create the file structure you need for roles.
A. TrueWhat formats may variables specified on the command line use when not using a file with the -e flag? (Choose all that apply.)
A. YAMLWhat are the default number of forks in Ansible?
A. 1Nowadays, the certification exams become more and more important and required by more and more enterprises when applying for a job. But how to prepare for the exam effectively? How to prepare for the exam in a short time with less efforts? How to get a ideal result and how to find the most reliable resources? Here on Vcedump.com, you will find all the answers. Vcedump.com provide not only Red Hat exam questions, answers and explanations but also complete assistance on your exam preparation and certification application. If you are confused on your EX407 exam preparations and Red Hat certification application, do not hesitate to visit our Vcedump.com to find your solutions here.