Using UCI as stand alone
UCI (Unified Configuration Interface) can be used as stand alone. With this you can make use of UCI in your own distribution. It's also useful in the future for writing and testing OpenWrt UCI configuration files and init scripts on a Linux box instead on the router.
UCI is maintained by nbd (Felix Fietkau) at http://nbd.name/gitweb.cgi?p=uci.git;a=summary
Checkout and compile UCI
cd ~
git clone git://nbd.name/uci.git ~/uci/
cd ~/uci/
makesudo make install
sudo mkdir -p /etc/configExample UCI config file (/etc/config/test):
config 'test' 'abc'
option 'test_var' 'value'openwrt@ubuntu-laptop:~/uci$ uci show test
test.abc=test
test.abc.test_var=valueopenwrt@ubuntu-laptop:~/uci$ uci set test.abc.test_var=foobaropenwrt@ubuntu-laptop:~/uci$ sudo uci commit testopenwrt@ubuntu-laptop:~/uci$ uci show test
test.abc=test
test.abc.test_var=foobarNotes
* Currently the config path is hardcoded to /etc/config/
* Init script related files such as rc.common has to be fixed to run as stand alone
(Last edited by forum2008 on 13 Apr 2008, 15:41)
