Bug#378717: [Adduser-devel] Bug#378717: adduser: warning introduced
as fix to 159345 should not be issued when adding system users
Stephen Gran
sgran at debian.org
Tue Jul 18 16:56:46 UTC 2006
This one time, at band camp, Sven Mueller said:
> The warning introduced to fix #159345 is also shown when adding system
> users. This does rarely make sense. An example is the cyrus-common-2.2
> package (but I would guess that there are others that act accordingly),
> which contains the /var/lib/cyrus directory, which is later (once the
> user cyrus was created) assigned to that user.
>
> Currently, adduser unconditionally displays the following warning while
> the cyrus user is created by postinst:
>
> Warning: that home directory does not belong to the user you are
> currently creating
>
> As one of the cyrus-imapd packagers, I have two options to avoid showing
> that warning to the user installing cyrus-common-2.2:
> 1) Don't include the /var/lib/cyrus directory in the package.
> Drawback: dpkg doesn't know the directory belongs to that package.
> 2) Redirect STDERR of adduser to /dev/null.
> Drawback: True errors of adduser aren't shown to the user anymore.
> So neither option seems to be the right one.
>
> Therefor, I see two options to resolve our bug #378518, and both would
> involve changes to the adduser package:
> 1) Make adduser suppress that warning when creating system users.
> 2) Add a commandline option to adduser to suppress that particular
> warning or all warnings.
>
> I kindly ask you to implement one of those.
>
> I thought about submitting this as a wishlist bug. However, since there
> are probably other packages suffering from the same "regression" (a
> bogus warning where there was no warning before), I decided against
> that. Feel free to change the severity as you like.
Adding --ignore-uid-mismatch or some such would be easy enough to do,
but it seems like the right thing to do here is to just make your
scripts use --no-create-home. This will skip this code path
altogether, and seems like the right thing to do if you ship the home
directory in the package anyway. This is what I do in my packages that
create users and also have the directory in the deb.
Take care,
--
-----------------------------------------------------------------
| ,''`. Stephen Gran |
| : :' : sgran at debian.org |
| `. `' Debian user, admin, and developer |
| `- http://www.debian.org |
-----------------------------------------------------------------
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
Url : http://lists.alioth.debian.org/pipermail/adduser-devel/attachments/20060718/9852d6a3/attachment.pgp
More information about the Adduser-devel
mailing list