Packaging openrc services in Debian/Devuan
Matthias Geiger
werdahias at riseup.net
Fri Sep 25 16:22:13 BST 2026
Hi Tom,
Sep 25, 2026 15:11:44 Tom <wirelessduck at gmail.com>:
> Hi,
>
> I'm attempting to package an openrc init script and conf.d for openbao for my personal use. The /etc/init.d/openbao script and /etc/conf.d/openbao are already developed by Alpine linux[0] so I don't need to be concerned with writing those.
>
> I would like to know if there are any guidelines available for the packaging configuration of these two files.
>
not yet. Mark and myself are working on it, but nothing official yet.
> Can I use dh_installinit for openrc-run init scripts? I'm guessing it would not yet support /etc/conf.d files?
>
No, not really. I started writing a new helper called deb-openrc-helper which should do that; but it is still very much WIP.
> Is openrc supported by update-rc.d and invoke-rc.d? I saw that policy mentions using update-rc.d for enabling autostarting of the daemon.[1]
No, those explicity cater only to SysV init scripts and not "native" openRC ones.
>
> Alternatively without any debhelper utility, is it sufficient to add the files into debian/package.install and call rc-update add/del in postinst/prerm?
Yes, that should do it.
>
> Is there any policy regarding whether a package should start/stop the service upon package install/remove/purge with `rc-service <service> start/stop` if we are not using update-rc.d?
>
> Do the files still go into /etc/init.d/ and /etc/conf.d/? I noticed openrc 0.64 was released upstream recently and wasn't sure if there was any change in preferred file paths for Debian.
>
With 0.64 RC_PATH is now supported. This means services can be started from under /usr to. Since my proposed Debian policy amendment to get proper openRC support would require that (also to not overwrite / conflict existing sysvinit ones), we decided to install the services to /usr/lib/rc/init.d (and conf.d), resp.
So I would advise to not install it for now, since once we ship 0.64 (and codify this in policy), a different path will be needed.
Let me know if you have any more questions.
Help in writing the helper program is much appreciated btw ;)
best,
werdahias
PS: sent from mobile, excuse the formatting/brevity
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.chiark.greenend.org.uk/pipermail/debian-init-diversity/attachments/20260925/af6af494/attachment.htm>
More information about the Debian-init-diversity
mailing list