title: Edit json file using ansible
body: <p>I am trying to edit a particular JSON file using Ansible. The file is present in remote servers which have to be logged in using LDAP authentication.</p>
  
  <p>The file path is <code>/etc/sensu/conf.d/client.json</code></p>
  
  <p>and the line that I want to edit is as follows:</p>
  
  <pre><code>"subscriptions": ["Nginx", "Primus", "B2B", "Docker_Process_Check", "EBS", "base"],
  </code></pre>
  
  <p>I want to add one more value (<code>"filebeat"</code>) in that line which after that should look like</p>
  
  <pre><code>"subscriptions": ["Nginx", "Primus", "B2B", "Docker_Process_Check", "EBS", "base","filebeat"],
  </code></pre>