Adding a VPN to truenas for external access

I’m new to Truenas, have installed and set up on my mini pc but would like to access remotely for storage etc.
I have subscribed to SurfShark for a VPN and now want to set up on Truenas. Found a few online guides but I’m getting very confused.
Do I need a specific domain name? Any help would be greatly appreciated as to the best way to access remotely. Many thanks.

I use duckdns.org, Is free and grant easy access to API (having a dinamic ip, Is easy to handle via TN cronjob).
Anyway, domains this day costs really nothing per year

Appreciate the response. So I will need a separate domain? That’s not a problem I have that, is there a guide on setting up truenas with duckdns?

For some solutions – yes. At least you should. I’m also using duckdns, but only as a “backup” dns. IMO, it is often having some troubles. Especially at UTC midnight.

Well, this topic is not directly related to truenas. You wanna access your LAN from the internet, right? There are several solutions for that:

  • You can set up a VPN server on your router.
  • You can set up a VPN server on your VPS.
  • You can set up some fancy/stylish stuff like Cloudflare Tunnel or ZeroTier. Aiui, you don’t need any domain for these. For the record – I never used them, so I can be wrong.
  • You can just expose the service you want by setting up the port forwarding on your router. Don’t recommend this, unless you know what you’re doing.
  • Perhaps there are other ways.
1 Like

As already pointed by @swc-phil, there are a lot of different solutions, also Tailscale is an extremely valid option and if i remember well no domain is needed.
Instead if you wanna use (like me) wg-easy/wireguard, a domain is quite mandatory to simplify clients management (no need to remap endpoint); with a cronjob you can keep your IP always valid using this simple command

curl http://www.duckdns.org/update/**domain**/**apikey**

i didn’t have realized of any problem, but i have to admit that i don’t use my VPN everyday/so often, and i use duckdns only for that (tn gui, services, ecc use another domain binded locally on pihole).
Also to mention, duckdns is not the only one exposing API, a lot of other service have this feature, and many of them are also integrated directly into some router/modem

I use a OPNSense Router and have wireguard configured on it for access when out and about. I also use cloud flare tunnels for access to services running on network, frigate, a TrueNAS documents share using webdav. I use wireguard for mostly ssh access to my network.

By far the easiest way to do this. You’re right about no domain, no dynamic DNS, none of that.

1 Like