How to enable/disable uwsgi Luci web server from SSH?

I am trying to enable and disable the Luci web interface over SSH for security - turn it on only when the GUI is needed, otherwise disable and use SSH with PKI.

I saw this article, and thought it would be straightforward

/etc/init.d/uhttpd disable
/etc/init.d/uhttpd stop

Unfortunately, on the Openwrt-based embedded system in this modem, /etc/init.d/uhttpd does not exist.

Some information about the environment:

root@E1500-1:/usr/sbin# uname -r
5.4.215
root@E1500-1:/usr/sbin#
root@E1500-1:/usr/sbin# cat /etc/os-release
NAME="TELiG"
VERSION="3.3.1"
ID="telig"
ID_LIKE="lede openwrt"
VERSION_ID="3.3.1"
BUILD_ID="a523d34194-7773c8d"
OPENWRT_BOARD="imx6/generic"
OPENWRT_ARCH="arm_cortex-a9_neon"
OPENWRT_TAINTS="no-all glibc busybox"
OPENWRT_DEVICE_PRODUCT="E-Series"
OPENWRT_DEVICE_REVISION="v1.1"
OPENWRT_RELEASE="TELiG 3.3.1 OpenWRT"

In the logs, I find references to uwsgi starting Luci: "/etc/uwsgi/vassals/luci-webui.ini has been spawned"

I found this site, but don't see anything about enable/disable of a server.

Can anyone point me to details on how to temporarily disable and re-enable the web server over SSH?

You are not running openwrt. How do we guess what webserver your vendor stuffed in your firmware?

1 Like

It appears you are using firmware that is not from the official OpenWrt project.

When using forks/offshoots/vendor-specific builds that are "based on OpenWrt", there may be many differences compared to the official versions (hosted by OpenWrt.org). Some of these customizations may fundamentally change the way that OpenWrt works. You might need help from people with specific/specialized knowledge about the firmware you are using, so it is possible that advice you get here may not be useful.

You may find that the best options are:

  1. Install an official version of OpenWrt, if your device is supported (see https://firmware-selector.openwrt.org).
  2. Ask for help from the maintainer(s) or user community of the specific firmware that you are using.
  3. Provide the source code for the firmware so that users on this forum can understand how your firmware works (OpenWrt forum users are volunteers, so somebody might look at the code if they have time and are interested in your issue).

If you believe that this specific issue is common to generic/official OpenWrt and/or the maintainers of your build have indicated as such, please feel free to clarify.

1 Like

This topic was automatically closed after 28 hours. New replies are no longer allowed.