Setting up daemontools to run services for an ordinary user
Wed 30 Apr 2025 21:27 CEST
I always forget how to do this, so I’m writing it here in part as a reminder for myself next time I need to do this.
These instructions are for using daemontools and daemontools-run packages on Debian.
- Create a directory
/etc/service/tonyg-services -
Create a file
/etc/service/tonyg-services/runcontaining#!/bin/sh exec setuidgid tonyg svscan /home/tonyg/servicesReplace
setuidgidwithsudo -uif you want to preserve supplemental groups. - Run
chmod a+x /etc/service/tonyg-services/run - Create
/home/tonyg/services - Create services ad libitum therein.
