add a new user stack with sudoers privileges (start of using sudo again)

This commit is contained in:
Jesse Andrews 2011-09-12 21:46:12 -07:00
parent 4f0c9bc6a8
commit 9a052d5d9c

View file

@ -51,5 +51,11 @@ if [ -f /root/.ssh/id_rsa.pub ]; then
fi
# set root password to password
echo root:password | chroot $DEST chpasswd
echo root:pass | chroot $DEST chpasswd
# create a stack user
chroot $DEST useradd stack -s /bin/bash -d /opt
echo stack:pass | chroot $DEST chpasswd
chroot $DEST chown -R stack /opt
echo "stack ALL=(ALL) NOPASSWD: ALL" >> $DEST/etc/sudoers