on our centos 8 servers, we have many custom services to start at boot time.
To split things between system and "our stuff", we put everything in our path /truc
Thoses services are enabled
via a kind of systemctl enable /truc/etc/systemd/machin.service
After a daemon-reload
that's ok. In my production context, job is done.
But on dev / QA contexts, /truc
is a remote NFS mounting on a file server.
At boot time, /truc doesn't contain services files, so none of them starts
I tried things with After=remote-fs.target
or RequiresMountsFor=/truc
but, anyway, file is not read has it is not yet present while booting
Any tips / hack ?!
Has this happens on a dev server, I can add a "hack.service" somewhere in the system path. But I cannot move/copy service files outside this NFS mount
thanks
/truc
(in the real root sense) is mounted before "switching root". (Some people like to have seperate/usr
partition. I guess you can try to find out how is that normally "handled" in the distro you use and see if the approach can apply to your case as well.)But I cannot move/copy service files outside this NFS mount
Btw I don't get this. Wouldn't you really be touching files (well, I mean, making symlinks) somewhere outside this mount anyway, when you have the services inside enabled?