I need to make a time syncing service for some SysV-based Linux system, but I want to use Ubuntu as a development environment. For this and some other reasons I've decided to use runit as a universal and convenient tool. But here are some troubles I have:
- How do I make it run in my SysV-based system? It seems it has a module (
runsvdir) that needs to be started. I've compiled from sources and donemake installas instructed, but see no changes in/etc/init.d/. Do I have to addrunsvdirto/etc/init.dmanually? - How do I make my console app react to control signals? Does it need some kind of special code to do it, or it is enough to do just
while(1){waitdata();processdata();}? I've searched for samples but find only bash scripts with sleep command.