[SOLVED] Using Dynamic DNS for OpenVPN server

Started by think124, December 16, 2017, 06:28:43 PM

Previous topic - Next topic
December 16, 2017, 06:28:43 PM Last Edit: December 18, 2017, 04:54:09 AM by think124
Hi there,
i have setup a working OpenVPN server by following the documentation online.  I was wondering if it is possible for the server to be setup so the client connects to a dynamic DNS hostname since the router WAN address could change.  I have dynamic DNS working on OPNsense but I didn't see any options to tie that to the OpenVPN configuration.

Thanks

I edited the .ovpn config file that is generated by OPNsense to reference the dynamic DNS address instead of the hard coded IP address.  This seems to work, but not sure if there is a more elegant way to do this?

Hi think24,


If I got you right, you can do that under VPN -> OpenVPN -> Client Export -> Host Name Resolution - > Dynamic DNS: YourDynamicDns.com

Then you export your client (.ovpn) file.


miroco

Thats how i do it.
Setup a DynDNS in services, and then pointed my openvpn client config to that dyndns.