Is here an official way running existing openwrt service under nobody or custom user? I want to restrict xray service (which is looks hudge) contating 1000 libraries and running under root on my router. I'm going to limit it it to socks proxy without tproxy support.
How can limit existing xray service to nobody or 'xray' user without chaning /etc/init.d/xray?
If the xray init script does not expose a user/group option, I would not expect a separate LuCI switch to do it safely. procd can drop privileges, but the service script has to set it (usually procd_set_param user xray and group xray after creating that user/group). I would avoid using nobody for this; a dedicated xray user is easier to reason about, and check permissions on the config/log directories before restarting.