title: Access ansible playbook results after run of playbook
body: <p>I am running an ansible script using <code>ansible-pull</code> on a remote machine(client side)  which I can't see .  </p>
  
  <p>I want to make sure that : </p>
  
  <ul>
  <li>ansible playbook are executed successfully then should send summary </li>
  <li>ansible playbook if not executed successfully should send summary of what failed </li>
  </ul>
  
  <p>Enabling ansible logs store information in some log file but was wondering if I can get the results of below ansible output via some variables predefined in ansible. </p>
  
  <pre><code>PLAY [localhost] ************************************************************** 
  
  GATHERING FACTS *************************************************************** 
  ok: [localhost]
  
  TASK: [Install the hello package] ********************************************* 
  ok: [localhost] =&gt; {"changed": false}
  
  TASK: [Install the cmatrix package] ******************************************* 
  ok: [localhost] =&gt; {"changed": false}
  
  PLAY RECAP ******************************************************************** 
  localhost                  : ok=3    changed=0    unreachable=0    failed=0  
  </code></pre>
  
  <p>If not then I will have to write the custom scripts to parse the logs , save information in some db on machine and send it back to our servers . </p>