logoalt Hacker News

jjgreenyesterday at 9:44 AM8 repliesview on HN

I've been almost convinced by systemd (and have switched to using it), but God the syntax of those service files is so ugly ...


Replies

zamadatixyesterday at 12:27 PM

Never thought I'd see hackers saying INI format looked ugly of all things. It's basic, sure, but that's a good thing for something meant to be easily editable by hand from any editor. Otherwise, it's just key value pairs in named sections, how ugly can it be about that?

show 3 replies
mrweaselyesterday at 12:40 PM

There's definitely some weirdness to certain parts of systemd service files, but was a huge improvement over Upstart and the old SysV-style init scripts.

Over all I think Systemd get way to much criticism. You don't have to use all the parts, but if you care to go through the documentation you'll find interesting features such as journald log-shipping and systemd-machined which can manage containers and VMs.

show 1 reply
egorfineyesterday at 3:57 PM

As a passionate systemd hater I would say I do not agree. Cron syntax is worse.

whateveracctyesterday at 12:24 PM

This is why I like NixOS. Defining systemd services in it is very neat.

SEJeffyesterday at 12:49 PM

Oh yes, because the well documented clean syntax of sys v init shell scripts was so nice.

If I never recall hacking in ulimit calls in the top of buggy shell scripts for crappy old services that done respect pam_limits it won’t be soon enough.

dominiweyesterday at 9:30 PM

Relevant, a golfed systemd polyglot file that is simultaneously an executable script: https://domi.work/blog/posts/compose_polyglot/

Yes, I have too much time sometimes... and I agree, I don't like the syntax.

linsomniacyesterday at 1:57 PM

Hard disagree. Compared to an init script, with all its boilerplate, I'd take a systemd unit file.

WesolyKubeczekyesterday at 12:20 PM

Could have been worse.

Could have been YAML.

Could have been XML.

show 4 replies