Files
parahub-mesh/files/etc/init.d/yggdrasil
Parahub AI e84d578ce4 fix(firmware): Three critical bugs found during MT3000 testing
1. Add yggdrasil init script (procd) — OpenWrt 25.x package doesn't
   include one, causing uci-defaults to fail on `/etc/init.d/yggdrasil
   enable` with set -e, leaving script in /etc/uci-defaults/ to re-run
   every boot and overwrite all config changes.

2. Delete default br-lan/lan before creating br-private — both bridges
   competing for eth0/eth1 port, preventing LAN cable access.

3. Per-device port mapping via /etc/parahub/port_map — filogic devices
   (MT3000, MT6000, WR3000) have eth0=WAN, eth1=LAN (opposite of
   qualcommax/ath79). Build.sh writes PORT_MAP, uci-defaults reads it.

Also: remove `set -e` from uci-defaults (too fragile for first-boot),
add SSH/HTTP firewall rules on yggdrasil zone for remote management.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-09 15:06:47 +00:00

18 lines
333 B
Bash
Executable File

#!/bin/sh /etc/rc.common
START=95
STOP=10
USE_PROCD=1
CONF_FILE="/etc/yggdrasil.conf"
start_service() {
[ -f "$CONF_FILE" ] || return 1
procd_open_instance
procd_set_param command /usr/sbin/yggdrasil -useconffile "$CONF_FILE"
procd_set_param respawn
procd_set_param stdout 1
procd_set_param stderr 1
procd_close_instance
}