[luci] Porting LuCI to Voyage (Debian)

Steven Barth steven at midlink.org
Mi Sep 17 13:20:12 CEST 2008


Hello Marius,
LuCI itself is in theory portable to other platforms. The core libraries are 
written to be compatible with any Linux environment by using POSIX functions, 
procfs, sysfs, standardized tools etc.
There are few things that have to be ported. We are in fact developing some 
parts of LuCI on Debian and other distros with the limitation that on this 
distros we cannot configure the system and its programs but only read and write 
our standardized configuration files that do nothing on these systems.

And this brings us to the one big problem of porting LuCI to other 
distributions:

LuCI and its design principles heavily rely on some kind of standardized 
configuration layer. In our case this is the UCI (the Universal Configuration 
Interface). Its a kind of 3 dimensional configuration format that can be parsed 
with a common linux shell allowing it to be directly used in init.d scripts.

This standardized configuration layer allows us to use only one API for every 
configuration task and avoids the need of writing configuration parsers and 
writers for the configuration format of every single program we want to 
support. 

This work is instead done by the OpenWrt maintainers who abstract the 
configuration files of programs to use UCI and write init-scripts that generate 
the native applications configuration file out of the UCI file and then launch 
the application with the appropriate parameters.

Other advantages of such a unified configuration layer are that you can generate 
documentation for your distribution more easily (e.g. LuCI includes a 
docbuilder for the UCI format).

But back to your problem:
As you see your distribution needs to offer a more or less stable configuration 
API for LuCI to build upon. This does not have to be UCI. It could also be 
something like an SQL-Database or a bunch of ini-files as long as this 
configuration layer provides a stable API for LuCI to rely on.

We do not want to have 10 to 20 different parser libraries only for the network 
configuration like Webmin has. Such things should not be part of a user 
interface.


Greetings
Cyrus


More information about the luci mailing list