How to run qvm-open-in-dvm whithout the prompt window to choose the VM

When I run qvm-open-in-dvm I always get a prompt window asking me to choose a DVM (that strangely includes the DVM templates).

How can I set up qvm-open-in-dvm so it always opens a DVM for a particular disposable template?


by default, qvm-open-in-dvm doesn’t prompt such a window.

It’s managed by RPC policies.

[user@dom0 ~]$ cat /etc/qubes/policy.d/90-default.policy | grep -i openinvm
qubes.OpenInVM          *           @anyvm          @dispvm     allow
qubes.OpenInVM          *           @anyvm          @anyvm      ask

So, if you got an ask instead of allow for the line with @dispvm, it will prompt you to choose a qube.

Notice the advice at the top of that file:

Do not modify this file, create a new policy file with a lower number in the
filename instead. For example 30-user.policy.

Maybe you have a file using the old syntax.
Make sure that file doesn’t exist: (if you don’t need it, delete it)


To choose the default disposable template, it’s in the global settings:
Qubes Apps Menu > Qubes Tools > Qubes Global Settings > qube defaults: disposable template

You can also choose a different disposable template for any qube in the ‘Advanced tab’ of the qube settings.