diff --git a/README.md b/README.md index ed81bad67..29ea7d419 100644 --- a/README.md +++ b/README.md @@ -56,7 +56,7 @@ Start an ImageBuilder of your choice, for example ath79-generic if your device i ```shell mkdir ./images/ -docker run -it -v $(pwd)/images:/images/ ghcr.io/openwrt/imagebuilder:ath79-generic-v22.03.5 +docker run -it -v $(pwd)/images:/images/ ghcr.io/openwrt/imagebuilder:ath79-generic-v23.05.3 ``` If your device is not part of ath79-generic profiles, you can replace it with another <target>-<subtarget> combination. For knowing which target and subtarget is best suited for your router, check out the page about it in the [OpenWrt's Table of Hardware][OpenWrt-ToH]. @@ -65,6 +65,7 @@ Within the container, add the `lime-packages` feeds: ```shell echo "src/gz libremesh https://feed.libremesh.org/master" >> repositories.conf +echo "src/gz libremesh_profiles https://feed.libremesh.org/profiles" >> repositories.conf echo "src/gz libremesh_arch_packages https://feed.libremesh.org/arch_packages/master/mips_24kc" >> repositories.conf echo "untrusted comment: signed by libremesh.org key a71b3c8285abd28b" > keys/a71b3c8285abd28b echo "RWSnGzyChavSiyQ+vLk3x7F0NqcLa4kKyXCdriThMhO78ldHgxGljM/8" >> keys/a71b3c8285abd28b @@ -95,6 +96,7 @@ Go to . Find your device. Click on the f ```shell echo "src/gz libremesh https://feed.libremesh.org/master" >> repositories.conf +echo "src/gz libremesh_profiles https://feed.libremesh.org/profiles" >> repositories.conf echo "src/gz libremesh_arch_packages https://feed.libremesh.org/arch_packages/master/mips_24kc" >> repositories.conf echo "untrusted comment: signed by libremesh.org key a71b3c8285abd28b" > keys/a71b3c8285abd28b echo "RWSnGzyChavSiyQ+vLk3x7F0NqcLa4kKyXCdriThMhO78ldHgxGljM/8" >> keys/a71b3c8285abd28b diff --git a/packages/bmx7-auto-gw-bw-mode/files/usr/sbin/bmx7-auto-bw-test b/packages/bmx7-auto-gw-bw-mode/files/usr/sbin/bmx7-auto-bw-test index ee6f1f685..f221d7b10 100755 --- a/packages/bmx7-auto-gw-bw-mode/files/usr/sbin/bmx7-auto-bw-test +++ b/packages/bmx7-auto-gw-bw-mode/files/usr/sbin/bmx7-auto-bw-test @@ -7,7 +7,7 @@ bw_test() { while [ -z "$bw" -a $try -lt $TRIES ]; do test=$({ wget -T5 -q $1 -O- | pv -n -b -t >/dev/null; } 2>&1) bw=$(echo $test | awk '{printf "%.0f",$NF/$(NF-1)*8}') - try=$(($try+1)) + try=$((try+1)) done echo $bw } diff --git a/packages/check-date-http/Makefile b/packages/check-date-http/Makefile index 868eafd34..cab37f7e5 100644 --- a/packages/check-date-http/Makefile +++ b/packages/check-date-http/Makefile @@ -19,7 +19,7 @@ define Package/$(PKG_NAME) CATEGORY:=LibreMesh MAINTAINER:=Gioacchino Mazzurco URL:=http://libremesh.org - DEPENDS:=+libuci-lua +lua +random-numgen \ + DEPENDS:=+libuci-lua +lua \ +luci-lib-httpclient PKGARCH:=all endef diff --git a/packages/check-date-http/files/etc/uci-defaults/check-date-http-cron b/packages/check-date-http/files/etc/uci-defaults/check-date-http-cron index 1dc3b4557..5ed89ddaa 100755 --- a/packages/check-date-http/files/etc/uci-defaults/check-date-http-cron +++ b/packages/check-date-http/files/etc/uci-defaults/check-date-http-cron @@ -6,5 +6,5 @@ unique_append() } unique_append \ - '*/20 * * * * ((sleep $(($(random-numgen) % 600)); check-date-http &> /dev/null)&)'\ + '*/20 * * * * ((sleep $((RANDOM % 600)); check-date-http &> /dev/null)&)'\ /etc/crontabs/root diff --git a/packages/eupgrade/Makefile b/packages/eupgrade/Makefile index fab7708d3..1e51b5fcd 100644 --- a/packages/eupgrade/Makefile +++ b/packages/eupgrade/Makefile @@ -11,7 +11,7 @@ define Package/$(PKG_NAME) CATEGORY:=Utilities TITLE:=$(PKG_NAME) provides semi automated firmware upgrades MAINTAINER:=Santiago Piccinini - DEPENDS:=+lua +lime-system +luci-lib-jsonc +luci-lib-nixio +libubus-lua +libuci-lua +random-numgen + DEPENDS:=+lua +lime-system +luci-lib-jsonc +luci-lib-nixio +libubus-lua +libuci-lua PKGARCH:=all endef diff --git a/packages/eupgrade/files/etc/uci-defaults/99-eupgrades-cron b/packages/eupgrade/files/etc/uci-defaults/99-eupgrades-cron index e1931c549..8afc37818 100755 --- a/packages/eupgrade/files/etc/uci-defaults/99-eupgrades-cron +++ b/packages/eupgrade/files/etc/uci-defaults/99-eupgrades-cron @@ -6,5 +6,5 @@ unique_append() } unique_append \ - '0 */6 * * * ((sleep $(($(random-numgen) % 120)); eupgrade-check &> /dev/null)&)'\ + '0 */6 * * * ((sleep $((RANDOM % 120)); eupgrade-check &> /dev/null)&)'\ /etc/crontabs/root diff --git a/packages/hotplug-initd-services/Makefile b/packages/hotplug-initd-services/Makefile index e2bbecda1..be1fb06ab 100644 --- a/packages/hotplug-initd-services/Makefile +++ b/packages/hotplug-initd-services/Makefile @@ -19,7 +19,7 @@ define Package/$(PKG_NAME) CATEGORY:=LibreMesh MAINTAINER:=Gioacchino Mazzurco URL:=http://libremesh.org - DEPENDS:=+libubox-lua +libubus-lua +random-numgen \ + DEPENDS:=+libubox-lua +libubus-lua \ +lua +luci-lib-nixio PKGARCH:=all endef diff --git a/packages/lime-docs/files/www/docs/lime-example.txt b/packages/lime-docs/files/www/docs/lime-example.txt index 0f88dbda8..15659d107 100644 --- a/packages/lime-docs/files/www/docs/lime-example.txt +++ b/packages/lime-docs/files/www/docs/lime-example.txt @@ -224,9 +224,9 @@ config net wirelessclientbackbone # list protocols 'wan' # Some of these protocols require the relative package "lime-proto-..." # list protocols 'static' # Set up a static IP (both IPv4 and IPv6 supported) # option static_ipv4 '192.168.1.2/24' -# option static_gateway_ipv4 '192.168.1.1' +# option static_gateway_ipv4 '192.168.1.1' # in static protocol, specifying an IP for the gateway is optional. Skip this line if no default route should be added on this interface. # option static_ipv6 '2a00:1508:0a00::1234/64' -# option static_gateway_ipv6 'fe80::1' +# option static_gateway_ipv6 'fe80::1' # in static protocol, specifying an IP for the gateway is optional. Skip this line if no default route should be added on this interface. ## (optional) configure lan1 for connection to other nodes, not for users connection: config net diff --git a/packages/shared-state-async/files/etc/uci-defaults/shared-state-net_stats-cron b/packages/shared-state-async/files/etc/uci-defaults/shared-state-net_stats-cron index c653162db..274ab3143 100755 --- a/packages/shared-state-async/files/etc/uci-defaults/shared-state-net_stats-cron +++ b/packages/shared-state-async/files/etc/uci-defaults/shared-state-net_stats-cron @@ -15,5 +15,5 @@ uci set shared-state.${mSc}.update_interval='120' uci commit shared-state unique_append \ - '*/3 * * * * ((sleep $(($RANDOM % 120)); shared-state-async insert net-stats < /tmp/shared-state/network_statistics.json &> /dev/null)&)' \ + '*/3 * * * * ((sleep $((RANDOM % 120)); shared-state-async insert net-stats < /tmp/shared-state/network_statistics.json &> /dev/null)&)' \ /etc/crontabs/root diff --git a/packages/shared-state-async/files/etc/uci-defaults/shared-state-publish-all-cron b/packages/shared-state-async/files/etc/uci-defaults/shared-state-publish-all-cron index 5f9183c2a..6587e50d4 100755 --- a/packages/shared-state-async/files/etc/uci-defaults/shared-state-publish-all-cron +++ b/packages/shared-state-async/files/etc/uci-defaults/shared-state-publish-all-cron @@ -6,5 +6,5 @@ unique_append() } unique_append \ - '*/30 * * * * ((sleep $(($RANDOM % 120)); shared-state-async-publish-all &> /dev/null)&)' \ + '*/30 * * * * ((sleep $((RANDOM % 120)); shared-state-async-publish-all &> /dev/null)&)' \ /etc/crontabs/root diff --git a/packages/shared-state-babel_links_info/Makefile b/packages/shared-state-babel_links_info/Makefile index 9b3d7724f..1b7def68a 100644 --- a/packages/shared-state-babel_links_info/Makefile +++ b/packages/shared-state-babel_links_info/Makefile @@ -12,7 +12,7 @@ define Package/$(PKG_NAME) TITLE:=Babel links module for shared-state MAINTAINER:=AsociaciĆ³n Civil Altermundi DEPENDS:=+lua +luci-lib-jsonc +ubus-lime-utils \ - +libubus-lua +random-numgen +shared-state-ref_state_commons shared-state-async + +libubus-lua +shared-state-ref_state_commons shared-state-async PKGARCH:=all endef diff --git a/packages/shared-state-babeld_hosts/Makefile b/packages/shared-state-babeld_hosts/Makefile index e409b6886..070450e84 100644 --- a/packages/shared-state-babeld_hosts/Makefile +++ b/packages/shared-state-babeld_hosts/Makefile @@ -19,7 +19,7 @@ define Package/$(PKG_NAME) CATEGORY:=LibreMesh MAINTAINER:=Gioacchino Mazzurco URL:=http://libremesh.org - DEPENDS:=+hotplug-initd-services +random-numgen \ + DEPENDS:=+hotplug-initd-services \ +lua +luci-lib-jsonc shared-state PKGARCH:=all endef diff --git a/packages/shared-state-babeld_hosts/files/etc/uci-defaults/shared-state-babeld_hosts-cron b/packages/shared-state-babeld_hosts/files/etc/uci-defaults/shared-state-babeld_hosts-cron index 9ecd8db66..cc30b458e 100755 --- a/packages/shared-state-babeld_hosts/files/etc/uci-defaults/shared-state-babeld_hosts-cron +++ b/packages/shared-state-babeld_hosts/files/etc/uci-defaults/shared-state-babeld_hosts-cron @@ -6,5 +6,5 @@ unique_append() } unique_append \ - '*/5 * * * * ((sleep $(($(random-numgen) % 120)); shared-state sync babeld-hosts &> /dev/null)&)'\ + '*/5 * * * * ((sleep $((RANDOM % 120)); shared-state sync babeld-hosts &> /dev/null)&)'\ /etc/crontabs/root diff --git a/packages/shared-state-dnsmasq_hosts/Makefile b/packages/shared-state-dnsmasq_hosts/Makefile index 010c253ac..e4881f908 100644 --- a/packages/shared-state-dnsmasq_hosts/Makefile +++ b/packages/shared-state-dnsmasq_hosts/Makefile @@ -19,7 +19,7 @@ define Package/$(PKG_NAME) CATEGORY:=LibreMesh MAINTAINER:=Gioacchino Mazzurco URL:=http://libremesh.org - DEPENDS:=+lua +luci-lib-jsonc +random-numgen \ + DEPENDS:=+lua +luci-lib-jsonc \ shared-state PKGARCH:=all endef diff --git a/packages/shared-state-dnsmasq_hosts/files/etc/uci-defaults/shared-state-dnsmasq_hosts-cron b/packages/shared-state-dnsmasq_hosts/files/etc/uci-defaults/shared-state-dnsmasq_hosts-cron index 63a2803ed..7b69e3d61 100755 --- a/packages/shared-state-dnsmasq_hosts/files/etc/uci-defaults/shared-state-dnsmasq_hosts-cron +++ b/packages/shared-state-dnsmasq_hosts/files/etc/uci-defaults/shared-state-dnsmasq_hosts-cron @@ -6,5 +6,5 @@ unique_append() } unique_append \ - '*/5 * * * * ((sleep $(($(random-numgen) % 120)); shared-state sync dnsmasq-hosts &> /dev/null)&)'\ + '*/5 * * * * ((sleep $((RANDOM % 120)); shared-state sync dnsmasq-hosts &> /dev/null)&)'\ /etc/crontabs/root diff --git a/packages/shared-state-dnsmasq_leases/Makefile b/packages/shared-state-dnsmasq_leases/Makefile index 09f0f04f0..422fa3a51 100644 --- a/packages/shared-state-dnsmasq_leases/Makefile +++ b/packages/shared-state-dnsmasq_leases/Makefile @@ -19,7 +19,7 @@ define Package/$(PKG_NAME) CATEGORY:=LibreMesh MAINTAINER:=Gioacchino Mazzurco URL:=http://libremesh.org - DEPENDS:=+libuci-lua +lua +random-numgen \ + DEPENDS:=+libuci-lua +lua \ +luci-lib-jsonc shared-state +shared-state-dnsmasq_hosts \ +luci-lib-nixio PKGARCH:=all diff --git a/packages/shared-state-dnsmasq_leases/files/etc/uci-defaults/90_dnsmasq-lease-share b/packages/shared-state-dnsmasq_leases/files/etc/uci-defaults/90_dnsmasq-lease-share index 701f85121..3e9e8eb4a 100755 --- a/packages/shared-state-dnsmasq_leases/files/etc/uci-defaults/90_dnsmasq-lease-share +++ b/packages/shared-state-dnsmasq_leases/files/etc/uci-defaults/90_dnsmasq-lease-share @@ -12,7 +12,7 @@ unique_append() } unique_append \ - '*/5 * * * * ((sleep $(($(random-numgen) % 120)); shared-state sync dnsmasq-leases &> /dev/null)&)'\ + '*/5 * * * * ((sleep $((RANDOM % 120)); shared-state sync dnsmasq-leases &> /dev/null)&)'\ /etc/crontabs/root exit 0 diff --git a/packages/shared-state-dnsmasq_servers/Makefile b/packages/shared-state-dnsmasq_servers/Makefile index 1223e6daa..70d21a2dd 100644 --- a/packages/shared-state-dnsmasq_servers/Makefile +++ b/packages/shared-state-dnsmasq_servers/Makefile @@ -19,7 +19,7 @@ define Package/$(PKG_NAME) CATEGORY:=LibreMesh MAINTAINER:=Gui iribarren URL:=http://libremesh.org - DEPENDS:=+lua +luci-lib-jsonc +random-numgen \ + DEPENDS:=+lua +luci-lib-jsonc \ shared-state PKGARCH:=all endef diff --git a/packages/shared-state-dnsmasq_servers/files/etc/uci-defaults/shared-state-dnsmasq_servers b/packages/shared-state-dnsmasq_servers/files/etc/uci-defaults/shared-state-dnsmasq_servers index 7adb6d63f..9271b1d92 100755 --- a/packages/shared-state-dnsmasq_servers/files/etc/uci-defaults/shared-state-dnsmasq_servers +++ b/packages/shared-state-dnsmasq_servers/files/etc/uci-defaults/shared-state-dnsmasq_servers @@ -10,5 +10,5 @@ unique_append() } unique_append \ - '*/5 * * * * ((sleep $(($(random-numgen) % 120)); shared-state sync dnsmasq-servers &> /dev/null)&)'\ + '*/5 * * * * ((sleep $((RANDOM % 120)); shared-state sync dnsmasq-servers &> /dev/null)&)'\ /etc/crontabs/root diff --git a/packages/shared-state-network_nodes/Makefile b/packages/shared-state-network_nodes/Makefile index b6158d2ad..88a91e40c 100644 --- a/packages/shared-state-network_nodes/Makefile +++ b/packages/shared-state-network_nodes/Makefile @@ -11,7 +11,7 @@ define Package/$(PKG_NAME) TITLE:=$(PKG_NAME) provides data-type for network nodes marked as reliable by user MAINTAINER:=Asociacion Civil Altermundi DEPENDS:=+shared-state +shared-state-nodes_and_links +lime-system +luci-lib-jsonc \ - +libubus-lua +random-numgen + +libubus-lua PKGARCH:=all endef diff --git a/packages/shared-state-network_nodes/files/etc/uci-defaults/shared-state-network_nodes-cron b/packages/shared-state-network_nodes/files/etc/uci-defaults/shared-state-network_nodes-cron index dc67e2c8b..595db4ad5 100644 --- a/packages/shared-state-network_nodes/files/etc/uci-defaults/shared-state-network_nodes-cron +++ b/packages/shared-state-network_nodes/files/etc/uci-defaults/shared-state-network_nodes-cron @@ -6,5 +6,5 @@ unique_append() } unique_append \ - '*/5 * * * * ((sleep $(($(random-numgen) % 120)); shared-state-multiwriter sync network_nodes &> /dev/null)&)'\ + '*/5 * * * * ((sleep $((RANDOM % 120)); shared-state-multiwriter sync network_nodes &> /dev/null)&)'\ /etc/crontabs/root diff --git a/packages/shared-state-nodes_and_links/Makefile b/packages/shared-state-nodes_and_links/Makefile index 6d44bdabc..c17ad8477 100644 --- a/packages/shared-state-nodes_and_links/Makefile +++ b/packages/shared-state-nodes_and_links/Makefile @@ -19,7 +19,7 @@ define Package/$(PKG_NAME) CATEGORY:=LibreMesh MAINTAINER:=Nicolas Pace URL:=http://libremesh.org - DEPENDS:=+lua +luci-lib-jsonc +random-numgen \ + DEPENDS:=+lua +luci-lib-jsonc \ shared-state +ubus-lime-location PKGARCH:=all endef diff --git a/packages/shared-state-nodes_and_links/files/etc/uci-defaults/shared-state-bat_nodes_and_links b/packages/shared-state-nodes_and_links/files/etc/uci-defaults/shared-state-bat_nodes_and_links index 27a449ee4..05b76dad3 100755 --- a/packages/shared-state-nodes_and_links/files/etc/uci-defaults/shared-state-bat_nodes_and_links +++ b/packages/shared-state-nodes_and_links/files/etc/uci-defaults/shared-state-bat_nodes_and_links @@ -6,5 +6,5 @@ unique_append() } unique_append \ - '*/5 * * * * ((sleep $(($(random-numgen) % 120)); shared-state sync nodes_and_links &> /dev/null)&)'\ + '*/5 * * * * ((sleep $((RANDOM % 120)); shared-state sync nodes_and_links &> /dev/null)&)'\ /etc/crontabs/root diff --git a/packages/shared-state-pirania/Makefile b/packages/shared-state-pirania/Makefile index 86f6cf843..c79d1a2db 100644 --- a/packages/shared-state-pirania/Makefile +++ b/packages/shared-state-pirania/Makefile @@ -19,7 +19,7 @@ define Package/$(PKG_NAME) CATEGORY:=LibreMesh MAINTAINER:=AsociaciĆ³n Civil AlterMundi URL:=http://libremesh.org - DEPENDS:=+lua +luci-lib-jsonc +random-numgen shared-state + DEPENDS:=+lua +luci-lib-jsonc shared-state PKGARCH:=all endef diff --git a/packages/shared-state-pirania/files/etc/uci-defaults/90-pirania-cron b/packages/shared-state-pirania/files/etc/uci-defaults/90-pirania-cron index 0522035de..79bc62afd 100755 --- a/packages/shared-state-pirania/files/etc/uci-defaults/90-pirania-cron +++ b/packages/shared-state-pirania/files/etc/uci-defaults/90-pirania-cron @@ -6,7 +6,7 @@ unique_append() } unique_append \ - '*/2 * * * * ((sleep $(($(random-numgen) % 30)); /etc/shared-state/publishers/shared-state-publish_vouchers && shared-state sync pirania-vouchers &> /dev/null)&)'\ + '*/2 * * * * ((sleep $((RANDOM % 30)); /etc/shared-state/publishers/shared-state-publish_vouchers && shared-state sync pirania-vouchers &> /dev/null)&)'\ /etc/crontabs/root exit 0 diff --git a/packages/shared-state/Makefile b/packages/shared-state/Makefile index 971081768..b377ddbc0 100644 --- a/packages/shared-state/Makefile +++ b/packages/shared-state/Makefile @@ -20,7 +20,7 @@ define Package/$(PKG_NAME) MAINTAINER:=Gioacchino Mazzurco URL:=http://libremesh.org DEPENDS:=+libuci-lua +lime-system +lua +luci-lib-jsonc +luci-lib-nixio \ - +iputils-ping +uclient-fetch +random-numgen + +iputils-ping +uclient-fetch PKGARCH:=all endef diff --git a/packages/shared-state/files/etc/uci-defaults/shared-state-publishers-cron b/packages/shared-state/files/etc/uci-defaults/shared-state-publishers-cron index c1fbde161..4ea7e7508 100755 --- a/packages/shared-state/files/etc/uci-defaults/shared-state-publishers-cron +++ b/packages/shared-state/files/etc/uci-defaults/shared-state-publishers-cron @@ -6,7 +6,7 @@ unique_append() } unique_append \ - '*/30 * * * * ((sleep $(($(random-numgen) % 1000)); shared-state-publish-all &> /dev/null)&)'\ + '*/30 * * * * ((sleep $((RANDOM % 1000)); shared-state-publish-all &> /dev/null)&)'\ /etc/crontabs/root unique_append \ diff --git a/packages/shared-state/files/usr/bin/shared-state-get_candidates_neigh b/packages/shared-state/files/usr/bin/shared-state-get_candidates_neigh index 1f9593921..d4aa72dac 100755 --- a/packages/shared-state/files/usr/bin/shared-state-get_candidates_neigh +++ b/packages/shared-state/files/usr/bin/shared-state-get_candidates_neigh @@ -20,7 +20,7 @@ lastRunFile="/tmp/shared-state-get_candidates_neigh.lastrun" lastRun=$(if [ -s $lastRunFile ]; then echo $(cat $lastRunFile); else echo -9999; fi) currUptime="$(get_uptime)" -[ "$(($currUptime - $lastRun))" -lt "30" ] && +[ "$((currUptime - lastRun))" -lt "30" ] && { cat "$cacheFile" exit 0