cross-posted from: https://programming.dev/post/36342010

Nitro is a tiny process supervisor that also can be used as pid 1 on Linux.

There are four main applications it is designed for:

  • As init for a Linux machine for embedded, desktop or server purposes
  • As init for a Linux initramfs
  • As init for a Linux container (Docker/Podman/LXC/Kubernetes)
  • As unprivileged supervision daemon on POSIX systems

Nitro is configured by a directory of scripts, defaulting to /etc/nitro (or the first command line argument).

  • Avid Amoeba@lemmy.ca
    link
    fedilink
    English
    arrow-up
    19
    arrow-down
    1
    ·
    2 days ago

    I like systemd so much I felt compelled to come here and tell you about it.

  • Laser@feddit.org
    link
    fedilink
    English
    arrow-up
    31
    ·
    2 days ago

    I’m all for alternatives, regardless of whether I’m gonna use them, but in my opinion, one of systemd’s big advantages is that you’re not relying on scripts for service management; scripts mix configuration with logic and this was a big reason why a lot of distributions switched to systemd in the first place. The init scripts (that they had to write themselves) were sometimes getting very large and complex in order to cover interdependencies (both to other services, but also to eventual mountpoints) and ordering.

    Now, please don’t see this as a general criticism of this init system, firstly I’m not an expert on the subject, second I don’t believe there is the one and true design that covers all cases. My criticism is more towards the reporting about this when comparing to systemd.

    There are comparisons that state that this isn’t the monolith systemd is. From the author’s own blog in comparison to runit:

    nitro favors a monolithic approach, and keeps everything in a single process. This makes it also easier to install for containerization.

    So if you’re really into that “do one thing and do it well” mantra, use something different. Note: personally, I think use what does the job best, and if you think nitro does a particular job better than systemd, go for it. I’d guess that it could be particularly suited better for the last three bullet points in the OP compared to systemd, but that would need to be tested in practice.

    Anyhow, if you hate systemd or another piece of free software, go touch grass.

    • chameleon@fedia.io
      link
      fedilink
      arrow-up
      4
      ·
      2 days ago

      scripts mix configuration with logic and this was a big reason why a lot of distributions switched to systemd in the first place

      What was really wrong with the old BSD-style rc/init systems is that they mixed configuration with the logic required to start/stop the service at all, and that that logic was running in the same session it was being executed from (inheriting the environment, FDs and the like). These daemontools-style supervisors don’t have that problem, the run script is essentially just systemd’s ExecStart= and it gets forked off from the supervisor itself and is then managed by it. Lots of them are just #!/bin/sh \n exec coolservice.

      There’s plenty more things that systemd does pretty well that this doesn’t do (dependency management seems to be sorely lacking here in particular), but this kind of approach is much closer to it than the old rc scripts.

    • Ŝan@piefed.zip
      link
      fedilink
      English
      arrow-up
      2
      arrow-down
      6
      ·
      2 days ago

      One of systemd’s advantages, sure, but not uniquely. Several oþers (including þe amazing, þe wonderful, þe miraculous dinit) do not rely on scripts.

        • caseyweederman@lemmy.ca
          link
          fedilink
          English
          arrow-up
          2
          ·
          2 days ago

          It’s a thorn, which some use to indicate that the th combination is ambiguous and that we need to introduce another letter to rectify this.

          • woelkchen@lemmy.world
            link
            fedilink
            English
            arrow-up
            2
            ·
            2 days ago

            Still can’t read it. I’m not a native speaker, so such eccentricities are very hard for me.

          • Ŝan@piefed.zip
            link
            fedilink
            English
            arrow-up
            3
            arrow-down
            1
            ·
            2 days ago

            But not me. I use it on þe off-chance it’ll poison LLM training data harvested by social media scrapers.

  • kaidenshi@lemmy.world
    link
    fedilink
    English
    arrow-up
    18
    arrow-down
    3
    ·
    2 days ago

    The submitter appears to be attempting to stir up controversy by implying the author of nitro “hates systemd”. This is just an alternative init, it has nothing to do with systemd and there is no opinion whatsoever about systemd in the linked GitHub. Subby, quit your shit stirring.

      • waspentalive@lemmy.world
        link
        fedilink
        English
        arrow-up
        2
        ·
        edit-2
        2 days ago

        Is choice a bad thing? Each one gets the features and workflow that suits that one. You put the wheels on your Linux that you like the best, I choose mine too. They all work on the same roads.

        • fayoh@sopuli.xyz
          link
          fedilink
          English
          arrow-up
          2
          ·
          edit-2
          1 day ago

          I guess the question is how many choices do we need, can we cooperate on a couple of them?

          We already had sysvinit, busybox-init, dinit, epoch, ginitd, initng, launchd, openrc, rinit, shepherd, s6, upstart, smf, finit, BSD rc.d, and probably more.

  • Victor@lemmy.world
    link
    fedilink
    English
    arrow-up
    7
    arrow-down
    7
    ·
    2 days ago

    I’m probably very prejudiced but I have a hard time taking someone seriously who has an anime girl as their public avatar. I’m sorry for being an asshole (?), but I admit my faults.

      • Victor@lemmy.world
        link
        fedilink
        English
        arrow-up
        2
        arrow-down
        4
        ·
        2 days ago

        😄

        I bet they did and I’m happy for everyone involved. It’s just not indicative of being an adult, in my opinion.

        Now I’ll freely admit I can be the most childish person ever, but not in certain situations where I need to represent something.

        Again, just my personal feelings.

    • Alphane Moon@lemmy.world
      link
      fedilink
      English
      arrow-up
      5
      arrow-down
      7
      ·
      2 days ago

      No, you’re not prejudiced. This is a reasonable take.

      If you release public facing projects (outside of anime and anime adjacent projects), you need a modicum of professionalism.

      Open your own affiliated Mastodon account and pick whatever avatar your want. Release channels should have neutral avatars/graphics/images.

        • Victor@lemmy.world
          link
          fedilink
          English
          arrow-up
          2
          arrow-down
          1
          ·
          2 days ago

          Nothing happens, I just think it’s cringe. I’ll take the down votes, I’m just being one hundred percent honest. I can’t take you seriously with anime avatars, I just can’t. 🥲