itsam
1
Hi Teltonika team,
we have many RUTX08 around the world and manage the I/O’s with a script.
In 07.13.4 is a syntax change (again), with 07.12.3 we can detect the OpenVPN by the name:
ifconfig | grep -q ‘VPNName’
now it’s replaced by the “interface”:
ifconfig | grep -q ‘tun_’
Also enable and disable OpenVPN was before possible with:
uci set openvpn.VPNNAME.enable=‘0’
now the syntax of the setting is:
uci set openvpn.inst1.enable=‘0’
Is there a better way to script this upgrade resistant?
Thanks.
pwsh
2
Yes, use API it shouldn’t change between versions. https://developers.teltonika-networks.com/
Hello @itsam,
Could you please confirm whether your issue has been resolved or if you still require any assistance?
Best regards,
itsam
5
Hi @Marija ,
still more questions than answers at the moment 
Unfortunately the examples [1] don’t show how to script it local on the device as /bin/sh script.
I need the following:
read input
if yes connect openvpn and enable output (high)
else disconnect openvpn and disable output (low)
I can use the api local in the script without authentication, right?
[1] https://developers.teltonika-networks.com/tutorials/
pwsh
6
It can be called locally without authentication by using /sbin/api
1 Like