Bug 143746 - Create buildmeister user for mortal RPM packaging
Create buildmeister user for mortal RPM packaging
Product: Fedora
Classification: Fedora
Component: rpm (Show other bugs)
All Linux
medium Severity medium
: ---
: ---
Assigned To: Jeff Johnson
Mike McLean
: FutureFeature
Depends On:
  Show dependency treegraph
Reported: 2004-12-26 13:36 EST by Kenneth Porter
Modified: 2007-11-30 17:10 EST (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2004-12-29 01:04:57 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Kenneth Porter 2004-12-26 13:36:29 EST
We recommend that RPM's be packaged as a mortal, but the default
rpm-build setup encourages users to package as root. I recommend that
the rpm-build package create the user buildmeister in its %pre script
and the directory tree /usr/src/redhat should be owned by this user.
Would-be packagers should be encouraged to su to this user to package.

This is particularly useful for non-programmers who just want to
install a 3rd party package "from source" using its SRPM.
Comment 1 Matthew Miller 2004-12-26 14:30:19 EST
"buildmeister"? :)

I don't think a special account should be used (or needed). What if
multiple people are building RPMs at the same time on the same system?

Instead, I think it'd be nicer to have this in the default macros:

%_topdir        %(echo $HOME)/rpmbuild
%_sourcedir     %{_topdir}/%{name}-%{version}
%_specdir       %{_sourcedir}
%_rpmdir        %{_topdir}/RPMS
%_srcrpmdir     %{_topdir}/SRPMS
%_builddir      %{_topdir}/BUILD
%_rpmfilename   %%{NAME}-%%{VERSION}-%%{RELEASE}.%%{ARCH}.rpm
%_tmppath       %(echo $HOME)/tmp

Comment 2 Kenneth Porter 2004-12-26 14:57:16 EST
I used "buildmeister" only because this seems to be what Red Hat is
using internally, as evidenced by the ownership in some tarballs. This
solution should be adequate for single-user workstations. For
multi-user servers, presumably the admin is knowledgable enough to
change the default to something more appropriate. Or a commented-out
entry can be include for him, along with a script to create the
canonical directory structure for each user. (I believe the old
cpanflute was able to create the directory tree and initial .rpmmacros

The only required change in your list appears to be _topdir. The
others should already be present in some reasonable form in
Comment 3 Matthew Miller 2004-12-26 15:02:56 EST
Although it's no longer really a requirement, I grate at seeing
default accounts with usernames over 8 characters.....
Comment 4 Jeff Johnson 2004-12-29 01:04:57 EST
rpm-build cannot establish a "buildmeister" conevntion
by itself. There is also no reason to dictatate how
packages are built, either by root, "buildmeister" or any other
account that anyone finds conevenient.
Comment 5 Matthew Miller 2004-12-29 01:10:22 EST
I agree. However, the current rpm-build package _does_ have a default
convention -- building packages as root in /usr/src/redhat. I
understand not doing anything new and fancy, but is there a reason to
continue doing that?
Comment 6 Kenneth Porter 2004-12-29 02:05:08 EST
Agreed. The fact that /usr/lib/rpm/macros points at /usr/src/redhat
and that directory is owned by root establishes a defacto policy of
encouraging users to package as root.

Note You need to log in before you can comment on or make changes to this bug.