title: Ansible community parted module asking "Are you sure you want to continue", is there an override
body: <p>I am trying to expand an <code>ext4</code> partition to fill a disk on Alpine using Ansible.</p>
  <p>Following the community parted module documentation <a href="https://docs.ansible.com/ansible/latest/collections/community/general/parted_module.html" rel="nofollow noreferrer">here</a> I should be able too. However when it comes to performing that action the returned error message says <code>&quot;Warning: Partition /dev/xvda3 is being used. Are you sure you want to continue?\n&quot;</code>.</p>
  <p>Is there anyway to force this action to proceed on a live system as it looks like Parted is asking for user interaction even though the <code>-s</code> flag is enable?</p>
  <p>The task I'm using:</p>
  <pre class="lang-yaml prettyprint-override"><code> - name: Read device information
    community.general.parted: device=/dev/xvda unit=MiB
    register: sdb_info
  
   - name: Extend an existing partition to fill all available space
    community.general.parted:
      device: /dev/xvda
      number: &quot;{{ sdb_info.partitions | length }}&quot;
      part_end: &quot;100%&quot;
      resize: true
      state: present
  </code></pre>
  <p>The full error from <code>ansible-playbook main.yaml -vvvv</code>:</p>
  <pre class="lang-yaml prettyprint-override"><code>fatal: [10.10.30.100]: FAILED! =&gt; {
      &quot;changed&quot;: false,
      &quot;err&quot;: &quot;Warning: Partition /dev/xvda3 is being used. Are you sure you want to continue?\n&quot;,
      &quot;invocation&quot;: {
          &quot;module_args&quot;: {
              &quot;align&quot;: &quot;optimal&quot;,
              &quot;device&quot;: &quot;/dev/xvda&quot;,
              &quot;flags&quot;: null,
              &quot;fs_type&quot;: null,
              &quot;label&quot;: &quot;msdos&quot;,
              &quot;name&quot;: null,
              &quot;number&quot;: 3,
              &quot;part_end&quot;: &quot;100%&quot;,
              &quot;part_start&quot;: &quot;0%&quot;,
              &quot;part_type&quot;: &quot;primary&quot;,
              &quot;resize&quot;: true,
              &quot;state&quot;: &quot;present&quot;,
              &quot;unit&quot;: &quot;KiB&quot;
          }
      },
      &quot;msg&quot;: &quot;Error while running parted script: /usr/sbin/parted -s -m -a optimal /dev/xvda -- resizepart 3 100%&quot;,
      &quot;out&quot;: &quot;&quot;,
      &quot;rc&quot;: 1
  }
  </code></pre>
  <p>Target host:</p>
  <ul>
  <li>Alpine-VM 3.16.2</li>
  <li>Parted 3.5</li>
  <li>Python 3.10.5</li>
  </ul>
  <p>Local:</p>
  <ul>
  <li>Ansible 2.13.3</li>
  <li>Python 3.10.4</li>
  </ul>