Login
You're viewing the functional.cafe public feed.
  • Nov 12, 2026, 12:29 AM

    So, what's the problem? Just snapshot the settings of a freshly factory-reset router, and then diff your changes against that.

    Well, say hi to /etc/uci-defaults

    It's a directory any package can put scripts in

    And each of those scripts will run on every boot (and possibly also on other occasions) and try to set some uci settings. Until it succeeds, then that script won't run again.

    If you're lucky, it will only set the defaults in the file in /etc/config that belongs to the package it's from

    💬 1🔄 0⭐ 0

Replies

  • Nov 12, 2026, 12:33 AM

    But in most cases, that package won't have its own config, and the script will set things in another package's config - /etc/config/network, or system, or luci, etc.

    So if you ask "what is the default /etc/config/network", there isn't a single answer. The defaults can change every time you install a package.

    💬 1🔄 0⭐ 0
  • Nov 12, 2026, 12:36 AM

    On the plus side, I learnt one way how not to design a config system for a router xD

    💬 1🔄 0⭐ 0
  • Nov 12, 2026, 12:56 AM

    I have a newfound appreciation for systemd-style /run > /etc > /usr config layering

    💬 0🔄 0⭐ 0