Ansible Adhoc Commands Assignment

1.ansible localhost -m group -a” name=deploy state=present” -b

2.ansible localhost -m user -a “name=deploy-user group=deploy state=present” -b

3.ansible localhost -m yum -a”state=present name=httpd” -b

4.ansible localhost -m service -a”name=httpd ” -b

5.ansible localhost -m copy -a”dest=/var/www/html src=index1.html” -b

6.ansible localhost -m copy -a”dest=/var/www/html src=second.html” -b

7. ansible localhost -m yum -a”state=present name=git” -b

9.ansible localhost -m reboot

10.ansible localhost -m file -a”state=touch path=/opt/devopsschool.txt” -b ansible localhost -m file -a”state=absent path=/opt/devopsschool.txt” -b