modified from https://github.com/haugene/docker-transmission-openvpn/blob/master/transmission/updatePort.sh
if we do it all in one big file like that I get a whole bunch of seg faults on the transmission commands, who knows.
install transmission freenas plugin
touch pia_client_id
touch pia_port
pkg install openvpn bash
add to crontab -e
* * * * * cd /usr/local/etc/openvpn/ && ./update_port.sh > /usr/local/etc/openvpn/update_port.log 2>&1