Tool to parse systemd unit files
Jesse Smith
jessefrgsmith at yahoo.ca
Fri Nov 15 16:46:42 GMT 2019
>
> I have updated my script to convert systemd services to init-d-script
>
> http://www.trek.eu.org/devel/sysd2v/
>
> there are 4 examples included, to better understand its output
>
> it works fine with basic services, even if some verbs are ignored
>
> it is intended to help maintainers to convert service files and it
> cannot work (yet) without human supervision, as there are some glitches
> with complex services
>
> changes since the previous version:
> - full conformance to unit file format, including lines ending with '\'
> - service types support (but not idle and dbus)
> - exec prefixes support (but not '@')
> - dependency handling (via LSB)
>
> I'm pretty satisfied by the actual script as it fits my needs, but tell
> me if you find it useful or if you need some feature to be implemented
>
> @sysvinit maintainers: I found a bug in init-d-script, as the status
> command ignores the PIDFILE, fixed with the attached patch
>
> @Lorenz: I think a runit output could be easily implementable or at
> least the read_unit parsing function could be used directly in your
> scripts, as it sets variables like: $ini_service_execstart
>
> ciao!
This script to convert systemd units to shell scripts looks very
promising. Would it be okay if we package this script in the "contrib"
directory of the SysV init source code? That might give the script more
wide-spread visibility with developers on other distributions.
- Jesse
More information about the Debian-init-diversity
mailing list