if not version_match or not self_version or version_match(self_version, "<60.0.1") then DIE("Minimal required version of Updater-ng for Turris repository is 60.0.1!") end if not board then local model = model or os_release["OPENWRT_DEVICE_PRODUCT"] or os_release["LEDE_DEVICE_PRODUCT"] if model:match("[Mm]ox") then board = "mox" elseif model:match("[Oo]mnia") then board = "omnia" elseif model:match("^[Tt]urris$") or model:match("[Tt]urris ?1\.?x") then board = "turris1x" else DIE("Unsupported Turris model: " .. tostring(model)) end end -- Script simplifying lists inclusion when older version of updater is used function list_script(list) if features["relative_uri"] then Script(list) else Script((repo_base_uri or "https://repo.turris.cz/hbs") .. "/" .. board .. "/lists/" .. list) end end ---------------------------------------------------------------------------------- if not turris_repo_included then list_script("repository.lua") turris_repo_included = true Export('turris_repo_included') end -- Updater itself Install('updater-ng', 'updater-supervisor', { critical = true }) Package('updater-ng', { replan = 'finished' }) Package('l10n_supported', { replan = 'finished' }) -- Critical minimum Install("base-files", "busybox", "dns-resolver", { critical = true }) -- Kernel Package("kernel", { reboot = "delayed" }) Package("kmod-mac80211", { reboot = "delayed" }) Install("kmod-ath9k", "kmod-ath10k", "kmod-ipt-offload", "kmod-nf-flow", "kmod-nf-nathelper", "kmod-br-netfilter", "kmod-usb2", { critical = true }) if board == "mox" then Install("kmod-rtc-ds1307", "kmod-gpio-button-hotplug", "kmod-ledtrig-heartbeat", "kmod-mwlwifi", "kmod-mwifiex-sdio", "kmod-btmrvl", { critical = true }) Install("mox-support", { critical = true }) Install("kmod-ath10k-ct", "zram-swap", { priority = 40 }) elseif board == "omnia" then Install("kmod-switch-mvsw61xx", "kmod-usb-serial-qualcomm", "kmod-gpio-pca953x", "kmod-i2c-mux-pca954x", "kmod-eeprom-at24", "kmod-ledtrig-default-on", "kmod-ledtrig-gpio", "kmod-ledtrig-heartbeat", "kmod-ledtrig-netdev", "kmod-ledtrig-oneshot", "kmod-ledtrig-timer", "kmod-ledtrig-transient", { critical = true }) Install("omnia-support", { critical = true }) elseif board == "turris1x" then Install("kmod-button-hotplug", "kmod-hwmon-lm90", "kmod-leds-gpio", "kmod-input-gpio-keys", "kmod-usb3", { critical = true }) Install("turris1x-support", { critical = true }) end Install("fstools", { critical = true }) -- OpenWRT minimum Install("procd", "ubus", "uci", "netifd", "firewall", { critical = true}) Install("ebtables", "odhcpd", "odhcp6c", "rpcd", { priority = 40 }) Install("opkg", "libustream-openssl", { priority = 40 }) Uninstall("wget-nossl", { priority = 40 }) -- opkg required SSL variant only -- Turris minimum Install("vixie-cron", "syslog-ng", { priority = 40 }) Install("logrotate", { priority = 40 }) Install("dnsmasq-full", { priority = 40 }) if board == "turris1x" then Install("unbound", "unbound-anchor", { priority = 40 }) Install("turris-btrfs", { priority = 40 }) else Install("knot-resolver", { priority = 40 }) end Install("ppp", "ppp-mod-pppoe", { priority = 40 }) -- Certificates Install("dnssec-rootkey", "cznic-cacert-bundle", "cznic-repo-keys", { critical = true }) -- Note: We don't ensure safety of these CAs Install("ca-certificates", { priority = 40 }) if true then -- Advanced dependencies guard -- It's Christmas time if board == "turris1x" or board == "omnia" then Install('christmas', { priority = 10 }) end -- Updater utility Install("updater-opkg-wrapper", { priority = 40 }) Package('updater-opkg-wrapper', { replan = 'finished' }) Package('localrepo', { replan = 'finished' }) Package('switch-branch', { priority = 40 }) -- Utility Install("ip-full", "tc", "genl", "ip-bridge", "ss", "nstat", "devlink", "rdma", { priority = 40 }) Install("iputils-ping", "iputils-ping6", "iputils-tracepath", "iputils-tracepath6", "iputils-traceroute6", { priority = 40 }) Install("iptables", "ip6tables", "conntrack", { priority = 40 }) Install("shadow", "shadow-utils", "uboot-envtools", "i2c-tools", { priority = 40 }) Install("openssh-client", "openssh-client-utils", "openssh-moduli", "openssh-server", "openssh-sftp-client", "openssh-sftp-server", "openssl-util", { priority = 40 }) Uninstall("dropbear", { priority = 40 }) Install("bind-client", "bind-dig", { priority = 40 }) Install("pciutils", "usbutils", "lsof", "btrfs-progs", { priority = 40 }) Install("lm-sensors", { priority = 40 }) Install("haveged", { priority = 40 }) Install("umdns", { priority = 40 }) -- Turris utility Install("turris-version", "start-indicator", { priority = 40 }) Install("turris-utils", "user-notify", "watchdog_adjust", { priority = 40 }) if for_l10n then for_l10n("user-notify-l10n-") end if board == "mox" then Install("mox-otp", { priority = 40 }) elseif board == "omnia" then Install("rainbow-omnia", { priority = 40 }) Install("libatsha204", { priority = 40 }) elseif board == "turris1x" then Install("rainbow", { priority = 40 }) Install("libatsha204", "update_mac", { priority = 40 }) end if board ~= "turris1x" then Install("schnapps", { priority = 40 }) end -- Wifi Install("hostapd-common", "wireless-tools", "wpad", "iw", "iwinfo", { priority = 40 }) if board == "mox" then Install("mwifiex-sdio-firmware", "ath10k-firmware-qca988x-ct", { priority = 40 }) else Install("ath10k-firmware-qca988x", { priority = 40 }) end end