Lab6
Making your own AddUser command
- open a terminal window
- create backups of passwd, shadow, and group files in the /etc folder
- go into your scripting folder
- create a .sh file
- you file should do these things:
- ask for users login name
- ask for users full name
- ask for users prefered bash shell
- get a new user id from the passwd file
- prompt the user to input his password by using passwd $login
- you need to do these things afterwards:
- append new lines for the user in passwd, shadow and group files, using the >> command
- make the user a home directory
- change ownership of the person's home directory with chown command
- modify the users home directory so others cant touch their stuff by using chmod 700