On Thu, 11 Jul 2019 12:05:10 -0500 Justin Pasher <just...@distribion.com> wrote:
> Moving it above the following block would ensure it's sourced first: this is a chicken-egg problem: init-d-script sources /etc/default/$NAME but $NAME is defined inside /etc/init.d/snmpd (that is $SCRIPTNAME) init-d-script could be modified, for example to source at first /etc/default/$(basename $SCRIPTNAME), but to retain backward compatibility it should source also /etc/default/$NAME and it would begin a sourcing mess with possible conflicts i think the init-d-script sourcing feature is not really useful and the right way to include variables it is to source the environment file inside the /etc/init.d/snmpd script, like batmand does for example: https://sources.debian.org/src/batmand/0.3.2-21/debian/batmand.init another possible way it could be to define DAEMON_ARGS directly inside /etc/default/snmpd, but I don't know how well it will play with other init systems ciao!