Mullvad CLI app creates new device all the time on TemplateBasedVM

I set up mullvad CLI utility in my sys-mullvad VM. I just added the necessary commands to /rw/config/rc.local.

It works fine except for Mullvad creating a new device for the connection every time I boot the VM. So very soon I reach the 5-device maximum and I have to manually delete the old device names. Funny enough I can’t login into the account with the CLI utility while I have too many devices, so I have to use my phone for it.

I tried adding /etc/mullvad-vpn to bind dirs, but it doesn’t seem to change anything.

How do I make the device name permanent?

1 Like

Are you running this in a disposable qube or a simple AppVM?

2 Likes

Not disposable. It’s a TemplateBasedVM and ServiceVM that provides network to other VMs.

1 Like

I’m not using the cli but it should work the same way. I just tested to keep a configuration using only the cli and it works with bind-dirs. All the files are in /etc/mullvad-vpn, so make sure those files are kept in /rw/bind-dirs/etc/mullvad-vpn, especially devices.json which contains the device name and keys.

1 Like