title: virt-install in python script
body: <p>I have been tasked to create virtual device using virt-install by writing it as a shell script.  How can I achieve the same in python script? I'm new to both virt-install and python. Thanks!</p>
  
  <pre><code>virt-install \
     --name centos7 \
     --ram 1024 \
     --disk path=./centos7.qcow2,size=8 \ 
     --vcpus 1 \
     --os-type linux \
     --os-variant centos7 \
     --network bridge=virbr0 \
     --graphics none \
     --console pty,target_type=serial \
     --location 'http://mirror.i3d.net/pub/centos/7/os/x86_64/' \ 
     --extra-args 'console=ttyS0,115200n8 serial'
  </code></pre>
  
  <p>(virtinstall.sh) and runs fine. </p>