In0edc2d5andafbe5ca, just prior to v24.06.0-rc1, support for deleting containers in the background was added. However, this also broke support for upgrading containers. Inafbe5cathe start script for containers was renamed from NAME.sh to S01-NAME.sh, but the container wrapper script's upgrade command was not updated. Neither was the cleanup and post-hook callbacks in confd! So when a container had been added to the system, the cleanup callback just simply deleted the script, preventing it from being recreated at ugprade This patch fixes the container identification code and also refactors the execd code to ensure that kill scripts (for deleting in background) and start scripts are run in the proper order *and* ensuring that execd also does not accidentally remove the container start script. Some cosmetic changes to the output at upgrade have also been added. Fixes #623 Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
Configuration Daemon
confd is the Infix configuration daemon that serves as the glue
between sysrepo and netopeer2 (NETCONF) and the UNIX system under
it all.
Factory & Failure Config
Infix supports both static and dynamically generated factory-config. At
boot the dynamic is always generated to /run/confd/factory-config.gen,
which is installed to /etc/factory-config.cfg and used by default, if
that file does not already exist. The same applies to the failure mode
configuration.
The following describes how a vendor/product specific config is found
and installed into /etc/factory-config.cfg before the dynamic one is
installed.
/etc/factory-config.cfg: built into the image, e.g., r2s/usr/share/product/<PRODUCT>/etc/factory-config.cfg, where the<PRODUCT>is determined from the VPD, which is available afterprobehas run, in/run/system.jsonas"product-name". The lower case version of the string is used
In the second option a script running just after probe will in fact
cp the complete product specific directory to /, meaning any file
and directory that is writable at runtime can be overloaded with device
specific versions.
Origin & References
Based on the Open Source dklibc/sysrepo_plugin_ietf_system project by Denis Kalashnikov.