From 7b3a05217c9a029833288d0617ddc6226f84aff0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Peter=20=C5=A0urda?= Date: Wed, 1 Mar 2023 08:15:29 +0100 Subject: [PATCH 1/2] Refactor and cleanup defaults - 49-network is now using versioning - 50-dropbear will make sure dropbear runs even if no version bump happened --- defaults/49-network | 8 +++++--- defaults/50-dropbear | 8 +++++++- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/defaults/49-network b/defaults/49-network index 357ae22..494c737 100644 --- a/defaults/49-network +++ b/defaults/49-network @@ -1,7 +1,9 @@ -[ "$(uci -q get luci.diag.dns)" = "bitmessage.org" ] && exit 0 +VERSION=1 -# make a significant change -/sbin/uci set luci.diag.dns='bitmessage.org' +[ "$(uci -q get defaults.version.network)" -ge "$VERSION" ] & exit + +# save version +/sbin/uci set defaults.version.network="$VERSION" # switch LAN to eth1 /sbin/uci set network.@device[0].ports='eth1' diff --git a/defaults/50-dropbear b/defaults/50-dropbear index 8468817..c97a1eb 100644 --- a/defaults/50-dropbear +++ b/defaults/50-dropbear @@ -1,6 +1,12 @@ VERSION=1 -[ "$(uci -q get defaults.version.dropbear)" -ge "$VERSION" ] && exit 0 +if [ "$(uci -q get defaults.version.dropbear)" -ge "$VERSION" ] +then + # may leave dropbear off after an upgrade + /sbin/service dropbear enable + /sbin/service dropbear restart + exit 0 +fi # save version /sbin/uci set defaults.version.dropbear="$VERSION" -- 2.45.1 From 80c1368f2ce4876f50ff02769ea616da0515cf90 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Peter=20=C5=A0urda?= Date: Wed, 1 Mar 2023 08:17:25 +0100 Subject: [PATCH 2/2] Remove cherrypy - I don't need it after all --- .buildbot/openwrt/build.sh | 3 --- 1 file changed, 3 deletions(-) diff --git a/.buildbot/openwrt/build.sh b/.buildbot/openwrt/build.sh index 0e8c425..3397a79 100755 --- a/.buildbot/openwrt/build.sh +++ b/.buildbot/openwrt/build.sh @@ -25,12 +25,9 @@ cat ${pwd}/feeds.conf >> feeds.conf ./scripts/feeds install -a make defconfig -echo 'CONFIG_PACKAGE_python3-packages=y' >> .config -echo 'CONFIG_PACKAGE_python3-packages-list="CherryPy==18.8.0"' >> .config # Enable collectd network encryption echo "CONFIG_PACKAGE_COLLECTD_ENCRYPTED_NETWORK=y" >> .config -make package/python3-packages/compile make package/asterisk-chan-quectel/compile make package/collectd/compile # no signing key -- 2.45.1