remove volumes, optimize build.sh

This commit is contained in:
Simon Zeyer
2026-08-25 21:07:57 +02:00
parent 2537dd1bc3
commit 66874a9dc7
3 changed files with 27 additions and 15 deletions
+21 -9
View File
@@ -1,19 +1,31 @@
#!/bin/bash
echo "src-git ha_cluster https://github.com/pgaufillet/openwrt-ha-feed.git" >> feeds.conf.default
grep -qxF 'src-git ha_cluster https://github.com/pgaufillet/openwrt-ha-feed.git' feeds.conf.default || echo 'src-git ha_cluster https://github.com/pgaufillet/openwrt-ha-feed.git' >> feeds.conf.default
rm -f ./sed* .config.tmp .config.old
# Update and install default package feeds
./scripts/feeds update -a && \
./scripts/feeds install -a
echo "CONFIG_TARGET_x86=y" > .config && \
echo "CONFIG_TARGET_x86_64=y" >> .config && \
echo "CONFIG_PACKAGE_dnsmasq-ha=y" >> .config && \
echo "CONFIG_PACKAGE_lease-sync=y" >> .config && \
echo "CONFIG_PACKAGE_owsync=y" >> .config && \
echo "CONFIG_PACKAGE_ha-cluster=y" >> .config && \
echo "CONFIG_PACKAGE_luci-app-ha-cluster=y" >> .config && \
sed -i 's/CONFIG_PACKAGE_dnsmasq=y/# CONFIG_PACKAGE_dnsmasq is not set/' .config && \
# Set target architecture
echo "CONFIG_TARGET_x86=y" > .config
echo "CONFIG_TARGET_x86_64=y" >> .config
make defconfig
# Enable HA packages
echo "CONFIG_PACKAGE_dnsmasq-ha=y" >> .config
echo "CONFIG_PACKAGE_lease-sync=y" >> .config
echo "CONFIG_PACKAGE_owsync=y" >> .config
echo "CONFIG_PACKAGE_ha-cluster=y" >> .config
echo "CONFIG_PACKAGE_luci-app-ha-cluster=y" >> .config
# Disable standard dnsmasq AFTER defconfig runs
sed -i 's/CONFIG_PACKAGE_dnsmasq=y/# CONFIG_PACKAGE_dnsmasq is not set/' .config
# Finalize config changes
make defconfig
# Download and compile
make -j$(nproc) download
make -j$(nproc) V=s