You have added sudo
to the qvm-run command.
This wont work because sudo will not operate through redirection(>)
My guess is that you are trying to copy the template to somewhere owned
by root. The sudo command runs the qvm-run
but the output write is
performed by user.
There are ways around this:
sudo su -
to get a proper root shell
Or qvm-run -p QUBE 'cat path_to_template'
| sudo tee template name > /dev/null
I would just copy the template to somewhere owned by user.
I cant replicate your error in setting up the repository.
What version of Qubes are you testing on?
I never presume to speak for the Qubes team.
When I comment in the Forum I speak for myself.