pleroma.debian.social

pleroma.debian.social

I guess since the whole "Flatpak creating a dependency on systemd" bullshit has surfaced this week there has been some other conversations about systemd going on throughout the Fediverse.

I've seen some oblique references to Debian making an effort to make OpenRC more viable as an alternate init system. That's about all I've gathered on my hit-n-run timeline surfing the last several days. Not sure if this is an official Debian project or just someone's wish list.

Anyone have the skinny? Links to actual discussions?

@RootMoose

Last I heard (a couple years ago?) there was a discussion about making room for optional alternate init systems, and it was shot down.

I have to reiterate (and forgive me for being preachy), that the conversation about systemd has to evolve beyond debating init systems, because systemd is not (merely) an init system. It's way, way more than that.

@rl_dane @RootMoose My understanding of Debian policy is that systemd is the default, not mandatory, and that other init systems are possible (but support for them may be patchy).

So I think if a package *assumes* systemd is present that’s a bug; obviously if it has a hard dependency that’s fine but it should say so, otherwise it shouldn’t assume more than ‘some init system’. In practice packages might not provide init scripts for other systems though.

@rl_dane @benjamineskola Yeah, this is all dated stuff that doesn't work any more iirc. I could give it a mess around when I find some focused seat time.

@RootMoose @benjamineskola

I might try throwing it on a vm to test later.

@2something @benjamineskola @rl_dane @RootMoose

fwiw there's a couple folks working a lot lately on bringing debians openrc support in par with gentoo/alpine, moving to native openrc scripts over sysvinit compat, etc, etc

so it might be a good option by then

@navi @benjamineskola @RootMoose @rl_dane @2something already works for sysinit, but nothing yet I would daily drive. Though I would really need testing of all init scripts that do not exist yet as native openrc service, such as ssh, apache, ...

@rl_dane @RootMoose @benjamineskola
you'll want https://salsa.debian.org/helmutg/dpkg-root-demo/-/merge_requests/11 and https://salsa.debian.org/debian/openrc/-/commits/wip/native. This works for a bare sysinit, but I did not test more than that. Note that this is highly experimental and you need to build your own packages.

@werdahias @benjamineskola @RootMoose

That's interesting, I didn't even know about debvm.

Is sysvinit better supported in #Debian right now?

@rl_dane @benjamineskola @RootMoose haha, no. It still works, but the default is still systemd and most is catered towards that.
replies
1
announces
0
likes
1

@werdahias @benjamineskola @RootMoose

Am disappoint. (But not surprised 🫠)

@rl_dane yeah....
Though I really like openrc, it is like a mature sysvinit. Once that support has landed and the rough edges are done this should be a very solid experience. The major missing services are ssh, dbus, bluetooth, some dns(avahi?), cron.

@werdahias

Just curious, is there a sample openrc script for ssh? I'd love to see what it looks like.

@werdahias

I'm guessing /sbin/openrc-run is itself a shell script? I was a little confused by the := substitution parameters at first, until I looked them up in the bash manpage.

Ah, it seems the leading ":" pads it so that if the variable is already assigned, it won't interpret it as a comand. That's interesting.

I tend to use

[[ -n ${foo:-} ]] || foo=bar

but I can see how

: ${foo:=bar}

would be preferable. The leading colon looks a little confusing, but it's easy enough to understand.

Overall, looks pretty readable/serviceable!

@rl_dane @werdahias

openrc-run is a c program, it handles starting and synchronizing dependencies, then it spawns a shell script helper that prepares the shell environment (e.g. by defining default functions and such), which then sources the conf.d and init.d

things like the $command variable are used by the default_start function for example

@navi @werdahias

Ah, so it spawns a subshell to interpret the config file? Because it totally looks like valid bash, except for functions which seem to be defined elsewhere. :)

@rl_dane @werdahias the init scripts are interpreted by /bin/sh (so not bash unless you set it yo bash)

it's just that we have a lot of code before the shell is even spawned to handle reliability

@navi @werdahias

Huh! Pretty sure /bin/sh would choke on the fancier substitution syntax, unless of course the distro defaults to ln -s /bin/bash /bin/sh

@rl_dane @werdahias := is posix, that sshd initd is fully posix sh

sometimes bashisms slip in, but rarely, i run all my gentoo systems with dash as /bin/sh, no issue

@navi @werdahias

Huh, you're right! I always assume POSIX shell lacks tons of features, and I'm usually surprised by how many of what I assumed to be "bashisms" it actually has. =)

@rl_dane @navi with any luck Debian forky will ship a usable openRC with fully native services

@werdahias @navi

Oh Pollyanna, you are far, far, far too good for this world. 🥲

(Hope springs eternal, though!)