Can't setup on NixOS

Unable to setup. I am using NixOS linux.

# twingate setup
Twingate Setup 1.0.60.47219 | 0.130.0
By continuing, you agree to the User Terms of Service (https://twingate.com/terms/user)
and acknowledge the Privacy Policy (https://twingate.com/privacy). [A]gree/[q]uit: A
Enter the name of your Twingate network (eg. "acme" for "acme.twingate.com"): NETWORK
checking...
NETWORK is a valid Twingate network
No such file or directory (os error 2)
Expected NETWORK but found ''. Try again? [Y/n]: n
Do you want to automatically start the Twingate service at boot? [Y/n]: n
No such file or directory (os error 2)
Do you want the Twingate service to automatically login after restart?
This requires saving authentication data in /var/lib/twingate (accessible only to root) [y/N]: y
No such file or directory (os error 2)
Do you want to automatically share application error reports with Twingate? [Y/n]: n
No such file or directory (os error 2)
Do you want to start Twingate now? [Y/n]:
Please run "twingate setup" first to configure access to your Twingate network.
To start desktop notifications, run `twingate desktop-start`.
Alternatively, you can run `/usr/bin/twingate-notifier console` in order to receive Twingate authentication requests in the console.
No such file or directory (os error 2)

This looks like it’s unable to find the /etc/twingate directory to write the configs.

If you run sudo twingate setup do you see a change in behaviour?

Yes, I’ve ran it with sudo. My /etc is readonly. Is there any workaround for this? Perhaps it might make sense to log the exact errors.

How can I write this config file manually?

FYI: when shell command example starts with # it means that it is being run as a root. When with $, it means that it is being run as a user

Have you enabled the service via
services.twingate.enable = true;
in your nixOS configuration?

Enabling the service should create the relevant /etc/twingate directory. Once you’ve enabled the service, twingate setup should work, but let us know if you’re still encountering errors.

Yes, I’ve found this option, thank you!
Other errors are discussed here: Can't setup: browser not found