This is the mail archive of the cygwin-apps@cygwin.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Building /etc/passwd from setup.exe


Pierre A. Humblet wrote:

# if USERDOMAIN isn't empty and
# USERDOMAIN isn't the hostname then we are in a domain
if [ ! -z "$USERDOMAIN" ] && [ "$USERDOMAIN" != "`hostname`" ] ; then
# domain user
type="-d"
fi

# Should we append rather than replace?
if [ ! -e /etc/passwd ] ; then
/bin/mkpasswd ${type} > /etc/passwd
fi
if [ ! -e /etc/group ] ; then
/bin/mkgroup ${type} > /etc/group
fi
**********
That file has no effect if it runs after passwd-grp.bat, because
then the passwd file already exists. I have observed that order, I don't know if it's deterministic.

So that's why domain users are not included, and why they are included
if they delete /etc/passwd and rerun /etc/postinstall/passwd-grp.sh.done
after setup, as has been suggested on the list.

This ``$type'' should only poll for the current user in the domain. I and my company would be very upset if I polled for 10's of thousands of users.

Earnie.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]