Sometimes one container should talk to the internet through a VPN provider and the rest of the server shouldn’t. You don’t need a special VPN container image for that. Unraid’s built-in WireGuard can do it per container.
The steps from the docs: download the WireGuard config file from your provider, go to Settings, VPN Manager and choose Import Config. That creates a new tunnel. Peer type of access defaults to VPN tunneled access for Docker, which is what you want. Click Apply and set the tunnel toggle to Active. Note the tunnel name, like wg1, and the DNS server from the provider’s config.
Then edit the container. Set Network Type to Custom: wg1, switch to Advanced view and put the provider’s DNS in Extra Parameters:
--dns=8.8.8.8
That’s the public resolver the docs use as a fallback. If your provider lists its own DNS server in the config, put that address there instead.
Test before you trust it. The docs use a Firefox container on the same tunnel: open whatismyipaddress.com and check that the IP is in the VPN server’s country, then dnsleaktest.com to see only your VPN’s DNS servers. I’d do that once for every new tunnel, since a container with the wrong DNS looks fine until you check.
There’s also a system-wide variant that sends all of Unraid’s traffic through the provider. I wouldn’t use it on a box full of services: only one such tunnel can be active, Unraid ignores the DNS settings from the imported config, and you may need to switch it off for Unraid updates and plugin installs.
The caveat is that a tunnel that is Active isn’t necessarily connected. The docs say WireGuard gives no error messages when something is wrong, so the leak test is your only real check.
Further reading: Unraid docs: Secure your outgoing communications
Going deeper: Why a Tailscale device vanishes after 180 days, and how to stop it