Port minimum

Rainer Müller raimue at macports.org
Thu Apr 23 17:01:19 PDT 2009


Scott Haneda wrote:
> Because I can not get dscl to play nice.  I need a user of vmail and a  
> group of vmail with u and g id of 5000.

sudo dscl . -create /Groups/vmail PrimaryGroupID 5000
sudo dscl . -create /Users/vmail UniqueID 5000
sudo dscl . -create /Users/vmail PrimaryGroupID 5000

This will add a group with the name vmail and gid 5000, add a new user
vmail with uid 5000 and set the primary group for this user.

If you additionally set a UserShell such as /usr/bin/false it will not
show up in the login window.

> I have made more complex ports in the past that added users, and those  
> always worked.  Since I can not get a OS X user made on the cli, I  
> figure, I can coax ports into doing the work for me.

Guess what MacPorts uses internally to create new users... dscl :-)

Rainer


More information about the macports-users mailing list