From: Guillermo Rodriguez Garcia <guille.rodriguez@gmail.com>
To: "ptxdist@pengutronix.de" <ptxdist@pengutronix.de>
Cc: Michael Olbrich <m.olbrich@pengutronix.de>
Subject: Re: [ptxdist] Resend: Home dir fixup for root in systemd
Date: Tue, 26 Jul 2016 15:19:59 +0200 [thread overview]
Message-ID: <CABDcavbGgCi04zPpbmCGiTKnx3ExcEbGpsUyLdDq2reMc_BWig@mail.gmail.com> (raw)
In-Reply-To: <20160726140925.16dc99e7@erd980>
[-- Attachment #1.1: Type: text/plain, Size: 1832 bytes --]
Wouldn't it be easier to either use a custom /etc/passwd, or create a /root
dir in the filesystem ? That sounds better than patching systemd.
Guillermo
2016-07-26 14:09 GMT+02:00 David Jander <david.jander@protonic.nl>:
>
> Dear Michael,
>
> I have prepared a patch against ptxdist git for the package systemd-230.
> I would like to know the right way to proceed to submit this patch, since
> I am
> not a ptxdist developer and am not familiar with how tools like
> git-ptxdist-patch are supposed to be used (to generate the correct series
> file
> in this case).
>
> The patch is really trivial and I don't know if it deserves so much work (I
> suspect that I have to clone the git repository of systemd first and apply
> all
> patches there, right?).
>
> What I am trying to fix here is the notion that systemd has about what the
> $HOME directory of the user 'root' (uid=0) should be. As it seems, in
> systemd
> this is hardcoded to be "/root", while ptxdist by default seems to insist
> in
> "/home" for some reason (according to shipped /etc/passwd). Here's the gist
> of what the patch does:
>
> --- systemd-230.orig/src/basic/user-util.c
> +++ systemd-230/src/basic/user-util.c
> @@ -123,7 +123,7 @@ int get_user_creds(
> *gid = 0;
>
> if (home)
> - *home = "/root";
> + *home = "/home";
>
> if (shell)
> *shell = "/bin/sh";
>
> Without this patch, things like services that declare "User=root" get
> screwed
> up with the wrong home directory for example.
>
> Thanks.
>
> Best regards,
>
> --
> David Jander
> Protonic Holland.
>
> _______________________________________________
> ptxdist mailing list
> ptxdist@pengutronix.de
--
Guillermo Rodriguez Garcia
guille.rodriguez@gmail.com
[-- Attachment #1.2: Type: text/html, Size: 2709 bytes --]
[-- Attachment #2: Type: text/plain, Size: 91 bytes --]
_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
next prev parent reply other threads:[~2016-07-26 13:19 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-07-26 12:09 David Jander
2016-07-26 13:19 ` Guillermo Rodriguez Garcia [this message]
2016-07-26 14:00 ` David Jander
2016-07-26 15:13 ` Ben Stuyts
2016-07-27 5:41 ` David Jander
2016-07-26 17:50 ` Guillermo Rodriguez Garcia
2016-07-27 5:51 ` David Jander
2016-07-27 12:04 ` Guillermo Rodriguez Garcia
2016-07-27 6:55 ` Michael Olbrich
2016-07-27 8:55 ` David Jander
2016-07-27 9:04 ` Michael Olbrich
2016-07-27 9:11 ` Artur Wiebe
2016-07-27 9:29 ` David Jander
2016-07-27 10:43 ` Michael Olbrich
2016-07-27 11:24 ` David Jander
2016-07-29 8:07 ` Tim Sander
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CABDcavbGgCi04zPpbmCGiTKnx3ExcEbGpsUyLdDq2reMc_BWig@mail.gmail.com \
--to=guille.rodriguez@gmail.com \
--cc=m.olbrich@pengutronix.de \
--cc=ptxdist@pengutronix.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox