Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.bugs.dist > #1149546

Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var

From Luca Boccassi <bluca@debian.org>
Newsgroups linux.debian.bugs.dist, linux.debian.policy
Subject Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var
Date 2023-06-13 22:10 +0200
Message-ID <GGiuZ-fH4F-3@gated-at.bofh.it> (permalink)
References (9 earlier) <GGgtb-fFDb-5@gated-at.bofh.it> <GGibD-fGIN-19@gated-at.bofh.it> <GGilj-fGM4-5@gated-at.bofh.it> <z5caR-7gO-3@gated-at.bofh.it> <GGilj-fGM4-5@gated-at.bofh.it>
Organization linux.* mail to news gateway

Cross-posted to 2 groups.

Show all headers | View raw


On Tue, 13 Jun 2023 at 20:51, Russ Allbery <rra@debian.org> wrote:
>
> Luca Boccassi <bluca@debian.org> writes:
>
> > That paragraph is in the context of StateDirectory= and
> > RuntimeDirectory=. These are unit files options, so it's up to
> > alternative init systems to provide alternative and integrate them in
> > the (eventual) init script, just as they are defined in the systemd
> > unit. I've mentioned those explicitly as you indicated earlier in this
> > thread:
>
> Ah!  Sorry, I did inded not understand the context correctly, and should
> have just not replied until I had a chance to read the context.  That's my
> fault.
>
> I agree with this statement with respect to systemd unit features.  This
> is a consequences of the fact that units are the preferred daemon
> configuration and package maintainers are allowed to use its features (GR
> 2019-002).  We should be encouraging them to use those features correctly
> and documenting how to do so, but that necessarily means that init scripts
> for use with other init systems will need to provide a version of the same
> feature in some other way.  We have had several GRs on this topic, and
> Policy does need to follow the outcome of those GRs unless someone
> overturns them with another GR.
>
> That being said:
>
> > Again, the rationale is: when there is a strong ownership model tied to
> > an individual service those are best as the lifecycle and permissions
> > are handled, when there is no owner or no specific owner or particular
> > metadata requirements then tmpfiles.d are best.
>
> I still am curious if it's safe to configure the same files in both
> tmpfiles.d and in the unit file, because it would make it much easier for
> those who want to support other init systems to do so.

As long as they both do the exact same thing, the one that runs last
is a no-op, I don't believe there would be any issue. But they have to
be kept in sync, not only w.r.t. directory name, but metadata too (ie:
ownership). See it this way: if the features provided by tmpfiles.d
and unit files (w.r.t. directories) were on a venn diagram, there
would be an intersection, yes, but there would not be a complete
overlap. There are things tmpfiles.d can do, that StateDirectory= and
friends cannot, and vice-versa.
In other words, for your stated goal of helping those who want to
support other init systems, it would only cover a subset of cases -
and these are real world cases, there are many services out there
making use of these features. We cannot be restricted, in terms of
unit files options, to what tmpfiles.d can provide, as that is not
realistic.

This is why I added that paragraph, indicating that other init systems
should provide equivalent functionality (and bear in mind I am not a
policy guru, so if 'should' is the wrong word I can change as needed,
it's perfectly fine as far as I'm concerned if other init systems
simply say, run everything as root and forget about security. It's
their choice what features they provide and I was not intending to
force them to do anything.).

Kind regards,
Luca Boccassi

Back to linux.debian.bugs.dist | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Luca Boccassi <bluca@debian.org> - 2023-06-04 13:20 +0200
  Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Simon McVittie <smcv@debian.org> - 2023-06-04 16:10 +0200
    Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Luca Boccassi <bluca@debian.org> - 2023-06-05 02:40 +0200
      Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Simon McVittie <smcv@debian.org> - 2023-06-05 11:00 +0200
        Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Luca Boccassi <bluca@debian.org> - 2023-06-05 13:20 +0200
        Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Thorsten Glaser <t.glaser@tarent.de> - 2023-06-13 17:50 +0200
          Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Thorsten Glaser <t.glaser@tarent.de> - 2023-06-13 18:20 +0200
          Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Bill Allombert <ballombe@debian.org> - 2023-06-13 18:20 +0200
            Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Marco d'Itri <md@Linux.IT> - 2023-06-13 18:40 +0200
              Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Ansgar <ansgar@43-1.org> - 2023-06-13 19:50 +0200
                Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Russ Allbery <rra@debian.org> - 2023-06-13 20:10 +0200
          Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Russ Allbery <rra@debian.org> - 2023-06-13 18:40 +0200
            Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Thorsten Glaser <t.glaser@tarent.de> - 2023-06-13 20:20 +0200
              Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Russ Allbery <rra@debian.org> - 2023-06-13 21:00 +0200
                Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Thorsten Glaser <t.glaser@tarent.de> - 2023-06-13 21:10 +0200
                Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Russ Allbery <rra@debian.org> - 2023-06-13 21:30 +0200
                Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Thorsten Glaser <t.glaser@tarent.de> - 2023-06-13 23:20 +0200
      Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Simon McVittie <smcv@debian.org> - 2023-06-05 11:20 +0200
        Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Luca Boccassi <bluca@debian.org> - 2023-06-05 13:20 +0200
    Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Helmut Grohne <helmut@subdivi.de> - 2023-06-05 14:20 +0200
    Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Simon McVittie <smcv@debian.org> - 2023-06-06 13:10 +0200
      Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Luca Boccassi <bluca@debian.org> - 2023-06-06 14:10 +0200
        Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Russ Allbery <rra@debian.org> - 2023-06-07 05:50 +0200
          Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Simon McVittie <smcv@debian.org> - 2023-06-07 12:40 +0200
            Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Luca Boccassi <bluca@debian.org> - 2023-06-07 13:00 +0200
          Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Luca Boccassi <bluca@debian.org> - 2023-06-07 12:40 +0200
      Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Mark Hindley <mark@hindley.org.uk> - 2023-06-13 15:10 +0200
        Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Mark Hindley <mark@hindley.org.uk> - 2023-06-13 19:10 +0200
          Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Russ Allbery <rra@debian.org> - 2023-06-13 20:00 +0200
            Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Luca Boccassi <bluca@debian.org> - 2023-06-13 21:50 +0200
              Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Russ Allbery <rra@debian.org> - 2023-06-13 22:00 +0200
                Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Luca Boccassi <bluca@debian.org> - 2023-06-13 22:10 +0200
                Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Ansgar <ansgar@43-1.org> - 2023-06-13 22:30 +0200
          Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Luca Boccassi <bluca@debian.org> - 2023-06-16 19:10 +0200
            Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Luca Boccassi <bluca@debian.org> - 2023-06-18 14:40 +0200
              Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Luca Boccassi <bluca@debian.org> - 2023-06-21 00:00 +0200
                Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Ansgar <ansgar@43-1.org> - 2023-06-25 18:00 +0200
                Bug#945269: debian-policy: packages should use tmpfiles.d(5) to create directories below /var Luca Boccassi <bluca@debian.org> - 2023-07-23 13:30 +0200

csiph-web