Create a playbook called regulartasks.yml which has the system that append the date to /root/datefile every day at noon. Name is job 'datejob'
Solution:
Solution as:
Does this meet the goal?
Correct Answer:
A
Create a file called requirements.yml in /home/sandy/ansible/roles to install two roles. The source for the first role is geerlingguy.haproxy and geerlingguy.php. Name the first haproxy-role and the second php-role. The roles should be installed in /home/sandy/ansible/roles.
Solution:
in /home/sandy/ansible/roles vim requirements.yml
Run the requirements file from the roles directory:
ansible-galaxy install -r requirements.yml -p /home/sandy/ansible/roles
Does this meet the goal?
Correct Answer:
A
Create a playbook called timesvnc.yml in /home/sandy/ansible using rhel system role timesync. Set the time to use currently configured nip with the server 0.uk.pool.ntp.org. Enable burst. Do this on all hosts.
Solution:
Solution as:
Does this meet the goal?
Correct Answer:
A
Create a file called requirements.yml in /home/sandy/ansible/roles 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 to node4.example.com" and when you curl again "Welcome to node5.example.com" The php-role should be used on the prod host.
Solution:
Solution as:
Check the proxy host by curl http://node3.example.com
Does this meet the goal?
Correct Answer:
A
Create a jinja template in /home/sandy/ansible/ and name it hosts.j2. Edit this file so it looks like the one below. The order of the nodes doesn't matter. Then create a playbook in /home/sandy/ansible called hosts.yml and install the template on dev node at /root/myhosts
Solution:
Solution as:
Does this meet the goal?
Correct Answer:
A