diff options
author | Christian Breunig <christian@breunig.cc> | 2024-02-07 21:34:45 +0100 |
---|---|---|
committer | Christian Breunig <christian@breunig.cc> | 2024-02-07 21:34:45 +0100 |
commit | 9b8e11e078c42e3ae86ebfa45fec57336f25a0af (patch) | |
tree | 576c12250def7c68147540ab6cb77cc0c3024bec /src | |
parent | 9d74ae52092e97aa0ef285df4d44a5eb7ae93fbf (diff) | |
download | vyos-1x-9b8e11e078c42e3ae86ebfa45fec57336f25a0af.tar.gz vyos-1x-9b8e11e078c42e3ae86ebfa45fec57336f25a0af.zip |
init: T2044: only start rpki if cache is configured
This extends commit 9199c87cf ("init: T2044: always start/stop rpki during
system boot") to check the bootup configuration if an RPKI cache is defined.
Only start RPKI if this is the case.
Diffstat (limited to 'src')
-rwxr-xr-x | src/init/vyos-router | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/init/vyos-router b/src/init/vyos-router index ac1cf249e..2b4fac5ef 100755 --- a/src/init/vyos-router +++ b/src/init/vyos-router @@ -448,14 +448,16 @@ start () restore_if_missing_postconfig_script run_postconfig_scripts - vtysh -c "rpki start" + tmp=$(${vyos_libexec_dir}/read-saved-value.py --path "protocols rpki cache") + if [ ! -z $tmp ]; then + vtysh -c "rpki start" + fi } stop() { local -i status=0 log_daemon_msg "Stopping VyOS router" - vtysh -c "rpki stop" for ((i=${#sub_inits[@]} - 1; i >= 0; i--)) ; do s=${subinit[$i]} log_progress_msg $s |