RE: Questions about user entry in ks.cfg file.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Just add the users in the %post via the normal Linux useradd command.
All works fine and well. Instead of doing that complicated sed of the
sudoers file, just append the line you need to the end of it.

-Georgi

-----Original Message-----
From: kickstart-list-bounces@xxxxxxxxxx
[mailto:kickstart-list-bounces@xxxxxxxxxx] On Behalf Of Petro
Sent: Saturday, May 31, 2008 2:09
To: Discussion list about Kickstart
Subject: Re: Questions about user entry in ks.cfg file.

So no ideas here?

Petro wrote:
> I am trying to add a small number of users in a ks.cfg such that they 
> are also in the "wheel" group so that
> 
> user --name=petro --groups="petro,wheel" 
> --password="$1$v4X7IlXv$fPls90.jmAV0Z/z..vZKj0" --iscrypted
> 
> <and three more>
> 
> Then in the %post section I:
> mv /etc/sudoers /etc/sudoers_orig
> cat /etc/sudoers_orig | sed 's/#
%wheel.*ALL$/%wheel\tALL=(ALL)\tALL/g' 
>  > /etc/sudoers
> chmod 0440 /etc/sudoers
> 
> I've tried this with various shiazit in the groups= bits, but it only 
> seems to modify/edit the /etc/passwd (e.g. petro:500:10:...) file, not

> /etc/group and /etc/gshadow.
> 
> So ultimately my goal is met--I can add these users such that they can

> use sudo, but it just doesn't seem to be right.
> 
> Is this correct behavior? This certainly isn't what the documentation 
> would lead me to believe.
> 
> Regards,
> Petro.
> 
> P.S. cat /etc/redhat-release
> Red Hat Enterprise Linux Server release 5.1 (Tikanga)
> 
> _______________________________________________
> Kickstart-list mailing list
> Kickstart-list@xxxxxxxxxx
> https://www.redhat.com/mailman/listinfo/kickstart-list

_______________________________________________
Kickstart-list mailing list
Kickstart-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/kickstart-list

______________

The information contained in this message is proprietary and/or confidential. If you are not the 
intended recipient, please: (i) delete the message and all copies; (ii) do not disclose, 
distribute or use the message in any manner; and (iii) notify the sender immediately. In addition, 
please be aware that any message addressed to our domain is subject to archiving and review by 
persons other than the intended recipient. Thank you.
_____________

_______________________________________________
Kickstart-list mailing list
Kickstart-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/kickstart-list

[Index of Archives]     [Red Hat General]     [CentOS Users]     [Fedora Users]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]

  Powered by Linux