BusyBox has its own httpd server which is smaller and simpler than uhttpd.
I just tested Luci and it looks like it works just fine on bb-httpd.
This may be a good option for tiny 4Mb routers like TP-Link WR740N.
As far as I understood, uhttpd was developed to make in process lua interpreter, to make a fast native support of ubus over JSON-RPC and to support https. So uhttpd is still better to use if disk space is not so limited.
On x64 platform bb-uhttpd took 8192 bytes (diff sizes of /bin/busybox with enabled and disabled httpd)
On the same x64 image uhttpd took 58Kb but on MIPS WRN1043ND it took 33189.
My question is:
Are any problems expected with busybox-httpd? As far as I see, there is no any rate limiting.
Did I correctly understand the original intent of development uhttpd?
Will you accept a PR with a new package luci-busybox-httpd similar to luci-nginx with configurations?
Does anybody else try such setup?
Some technical details
I used the feature flags to make httpd smaller:
HTTPD_ACL_IP=n Remove access by IP checks because this will be handled by firewall
HTTPD_DATE=n Disable Date header
HTTPD_LAST_MODIFIED=n Disable Last-Modified to use ETag instead
HTTPD_ETAG=y use ETag which is faster and easier than Last-Modified
Wow, I see you’ve been working on this for a long time, but I’m afraid it looks like the package you want to add would only be used by you — which isn’t a problem at all.
However, there must be a reason why OpenWrt hasn’t been using BusyBox httpd as the default for over 12 years now:
I understand that you’re mainly trying to do this to save some space, but this isn’t really the solution. With each OpenWrt release that includes newer versions of various software, the space requirements increase anyway. I think that instead of spending so much time trying to add another package, it would’ve been better to just spend 20 bucks and get a router with plenty of storage.
We already have plenty of other web servers available, so adding yet another one will just create more hassle for maintainers. What surprised me is how many people actually commented on that pull request and how much time was spent on it — it’s quite an interesting surprise.
If this package gets merged — which I hope it won’t — it means it’ll suddenly become available for all OpenWrt users, and that would increase build time and resource usage (HDD, CPU, etc.). Is that really the right way to go, when you could just enable it in the BusyBox config yourself if you’re building OpenWrt on your own?