Attempting to rebuild luci-app-radius

I'm interested in re-creating luci-app-radius for Freeradius3.

There's a couple of git repositories that are "luci-app-freeradius3", but there just clones of "luci-app-radius" from https://github.com/MuJJus/luci-app-radius and they're all 7 years old and only support Freeradius2.

After going through the thorough Freeradius Guide I think it's impractical to have luci-app-radius provide a "simple" radius configuration, so I've removed that portion of it. However, for most home users or small businesses that might want to manage APs and users for their wifi, I think that this would be ideal.

I've started working on a new version and have gotten it set up to point to the correct file locations for Freeradius3 users and clients, but I've run into a LuCI issue that I have no idea how to tackle.

When I open the "Services" "Radius" page, I get the following error:

/usr/lib/lua/luci/dispatcher.lua:1347: module 'luci.cbi' not found:
        no field package.preload['luci.cbi']
        no file './luci/cbi.lua'
        no file '/usr/share/lua/luci/cbi.lua'
        no file '/usr/share/lua/luci/cbi/init.lua'
        no file '/usr/lib/lua/luci/cbi.lua'
        no file '/usr/lib/lua/luci/cbi/init.lua'
        no file './luci/cbi.so'
        no file '/usr/lib/lua/luci/cbi.so'
        no file '/usr/lib/lua/loadall.so'
        no file './luci.so'
        no file '/usr/lib/lua/luci.so'
        no file '/usr/lib/lua/loadall.so'
stack traceback:
        [C]: in function 'require'
        /usr/lib/lua/luci/dispatcher.lua:1347: in function '_cbi'
        /usr/lib/lua/luci/dispatcher.lua:1024: in function 'dispatch'
        /usr/lib/lua/luci/dispatcher.lua:1000: in function 'dispatch'
        /usr/lib/lua/luci/dispatcher.lua:479: in function </usr/lib/lua/luci/dispatcher.lua:478>

I'll poke through https://openwrt.org/docs/guide-developer/luci?s[]=cbi to see if I can figure anything out, but if anyone is interested or capable of helping out, please let me know.

luci has been seeing quite active development in recent years, along with a slow push from lua to client-side javascript orchestrating an rpcd backend with more fine grained ACLs. While there is some backwards compatibility for lua left (via luci-compat), you'll likely have to cut deeper than that.

opkg update && opkg install luci-compat

Ah, sweet. Thanks.

Should I keep asking questions here about continuing my work on this?

For instance "Save & Apply" doesn't update the freeradius files, it just updates the config files. There's a script written that updates the freeradius files, but it doesn't get run on "Save & Apply". I'll see what I can find.

Also, do you recommend any articles or reference for converting the cbi interface to javascript?

this is for freeradius2

Yes ...

So, that's where I am starting. I'll have a git up of my current work soon. But I would like to modernize this.

OK, I'm sort of satisfied with an initial release of my stuff.

If I can find some place to read about converting the interface to JavaScript to modernize it, I'll tackle that next. It's really not much different than the original, but I hope someone finds it helpful: