Wublide
1
I'm trying to setup a netwatch, but this syntax do not seems to work, what I'm doing wrong?
:local endpoint ""
:set endpoint [/interface/wireguard/peers/print proplist=current-endpoint-address where name="john - smartphone"]
/tool/fetch http-method=post certificate=redacted url="redacted" http-data="type=info&title=Mytitle&body=The john's smartphone connected from $endpoint to the vpn&urls=redacted" keep-result=no
These are commands specific to your configuration, known only to you.
The problem is "redacted".
Wublide
3
The fetch command, less the $endpoint variable, works. The problem lies between the :set command and how the variable is called in the fetch command
Wublide
4
solved by editing the set command to
:set endpoint [interface/wireguard/peers/get [find name="john - smartphone"] current-endpoint-address]