title: Ansible: How would I insert a text string in the middle of a conf file using an Ansible playbook?
body: <p>I need to add text stating 'Allow all' right underneath 'Order allow,deny'
  So this:</p>
  
  <pre><code># Restrict access to the server...
  &lt;Location /&gt;
    Order allow,deny
  &lt;/Location&gt;
  </code></pre>
  
  <p>Should look like this:</p>
  
  <pre><code># Restrict access to the server...
  &lt;Location /&gt;
    Order allow,deny
    Allow all
  &lt;/Location&gt;
  </code></pre>
  
  <p>My Ansible playbook block looks like this so far:</p>
  
  <pre><code>  - name: Enable access to the server                                                                                                                                                                     
      lineinfile:
        destfile: /etc/cups/cupsd.conf
  </code></pre>