VyOS systemd target to use as readiness indicator

Hello,

is there any systemd target indicating the complete readiness of the system? We would need such a thing to ensure some custom services are only started, as /config got fully available. Currently we run into the issue, that on boot ConditionPathExists fails on a file within /config, even though our unit requires vyos.target. We also tried with RequiresMountsFor=/config, but that didn’t yield any results as well. Now we’re kinda out of ideas on how to proceed and make sure these units start properly after reboots.

EDIT: When removing the unit conditions altogether, the service starts just fine, so the files in question must be ready and readable. We need the conditionals though, as the configs for these services are not deployed as part of our image creation, but after the routers are setup and running live.

Best regards

One can check ConditionPathExists=/tmp/vyos-config-status to determine that boot configuration has completed (with possible errors; the value in the file is 0 success; 1 (some) failures).
Cf. vyos-1x/python/vyos/utils/boot.py at current · vyos/vyos-1x · GitHub
Boot configuration itself is called from vyos-router.service.
Of course, you will need to poll for the existence of the above file, in order for a service to wait on the condition, rather than a single check of existence.

I see, so any custom service having to rely on this should be triggered via systemd path trigger watching /tmp/vyos-config-status instead of having that as a condition for service startup itself?