confd: fix duplicate keystore log messages at boot

Only install the keys on CHANGE event, fixes this annoying issue:

Nov 5 01:32:10 ix confd[2011]: Installing HTTPS gencert certificate "self-signed"
Nov 5 01:32:10 ix confd[2011]: Installing SSH host key "genkey".
Nov 5 01:32:11 ix confd[2011]: Installing HTTPS gencert certificate "self-signed
Nov 5 01:32:11 ix confd[2011]: Installing SSH host key "genkey".

Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
This commit is contained in:
Joachim Wiberg
2026-03-20 16:18:09 +01:00
parent 9e7cdf492f
commit 5583b97da9
+1 -2
View File
@@ -331,8 +331,7 @@ int keystore_change(sr_session_ctx_t *session, struct lyd_node *config, struct l
switch (event) {
case SR_EV_UPDATE:
rc = keystore_update(session, config, diff);
break;
return keystore_update(session, config, diff);
case SR_EV_CHANGE:
if (diff && lydx_find_xpathf(diff, XPATH_KEYSTORE_SYM))
rc = interfaces_validate_keys(session, config);