How to use qubesctl to download new templates?

From #3447, I see that qubes-dom0-update is being phased out and will be finally replaced with qubesctl. Hence, I’m trying to practice using qubesctl for all my actions.

I’m trying to update Whonix to version 16 following this guide. It instructs me to use the following command to download templates for Whonix 16.

sudo qubes-dom0-update --enablerepo=qubes-templates-community qubes-template-whonix-gw-16 qubes-template-whonix-ws-16

I want to use the equivalent version of qubesctl, but Google doesn’t return anything relating to installing new templates with qubesctl, and I don’t know how to do it.

1 Like

If you’re still on 4.0 a ‘sudo qubes-dom0-update …’ should work. If you’re on 4.1 you may try a

sudo qvm-template install --enablerepo=qubes-templates-community qubes-template-whonix-gw-16 qubes-template-whonix-ws-16

Cheers :slight_smile:

1 Like

You will have to do it the way it is described in the Whonix documentation. I vaguely remember that with R4.0 and Whonix-15 everything could be installed with one qubesctl command (which in turn invoked qubes-dom0-update). Whonix 16 install instructions do not have this option and there is probably a reason for it.

1 Like

You can use a state like this to install templates

    - name: qubes-template-debian-10-minimal
    - fromrepo: qubes-templates-itl

1 Like