check playbook: site.yml
[iyunv@localhost nginx_ntp]# ansible-playbook -i hosts site.yml -f 10
PLAY [apply common configuration to all nodes] **********************************************************************************************
TASK [Gathering Facts] **********************************************************************************************************************
ok: [192.168.34.130]
ok: [192.168.34.129]
TASK [common : install ntp server] **********************************************************************************************************
ok: [192.168.34.129]
ok: [192.168.34.130]
TASK [common : set zone info] ***************************************************************************************************************
changed: [192.168.34.130]
changed: [192.168.34.129]
TASK [common : update time] *****************************************************************************************************************
changed: [192.168.34.130]
changed: [192.168.34.129]
TASK [common : configure ntp file] **********************************************************************************************************
changed: [192.168.34.129]
changed: [192.168.34.130]
TASK [common : start ntp server] ************************************************************************************************************
changed: [192.168.34.130]
changed: [192.168.34.129]
TASK [common : test to see if selinux is running] *******************************************************************************************
ok: [192.168.34.130]
ok: [192.168.34.129]
RUNNING HANDLER [common : restart ntp] ******************************************************************************************************
changed: [192.168.34.129]
changed: [192.168.34.130]
PLAY [configure and deploy the webserver and application code] ******************************************************************************
TASK [Gathering Facts] **********************************************************************************************************************
ok: [192.168.34.130]
ok: [192.168.34.129]
TASK [web : install nginx] ******************************************************************************************************************
ok: [192.168.34.130]
ok: [192.168.34.129]
TASK [web : add user] ***********************************************************************************************************************
changed: [192.168.34.129]
changed: [192.168.34.130]
TASK [web : write config] *******************************************************************************************************************
changed: [192.168.34.129]
changed: [192.168.34.130]
TASK [web : ensure nginx is running] ********************************************************************************************************
changed: [192.168.34.129]
changed: [192.168.34.130]
RUNNING HANDLER [web : restart nginx] *******************************************************************************************************
changed: [192.168.34.129]
changed: [192.168.34.130]
PLAY RECAP **********************************************************************************************************************************
192.168.34.129 : ok=14 changed=9 unreachable=0 failed=0
192.168.34.130 : ok=14 changed=9 unreachable=0 failed=0
[iyunv@localhost nginx_ntp]# |