Luci / Custom Commands
hannu.nyman at iki.fi
Fri Apr 16 07:49:59 BST 2021
e9hack kirjoitti 16.4.2021 klo 8.37:
> I want like to add the following command to Luci/Custom Commands:
> echo "/" > /proc/net/xt_recent/SSH_BLOCK
> But I can only add:
> echo "> /proc/net/xt_recent/SSH_BLOCK"
> How can I do it?
I thought that easiest might be yo manually edit the uci config file, but I
experience no difficulty even in LuCI with 21.02, when I test your example
from GUI. It is visible in GUI, and gets in right format into /etc/config/luci
Also execution seems to go (I will send the screenshot separately as it might
not get into).
So I am not sure what is the exact difficulty??? If the difficulty is in
">" and "/" plus passing them to the shell combo.
One easy solution might to manually edit a script file with that required
command into /etc and then using LuCI only to execute that script. The
LuCI commands feature is not meant for really complex things.
More information about the openwrt-devel