shinobi user configured for keylogin
All checks were successful
learn org at code.softwareshinobi.com/linux.softwareshinobi.com/pipeline/head This commit looks good
All checks were successful
learn org at code.softwareshinobi.com/linux.softwareshinobi.com/pipeline/head This commit looks good
This commit is contained in:
48
server/provision/users/shinobi/provision.bash
Executable file
48
server/provision/users/shinobi/provision.bash
Executable file
@@ -0,0 +1,48 @@
|
||||
#!/bin/bash
|
||||
|
||||
##
|
||||
## This script installs stuff
|
||||
## to set up a linux server
|
||||
## suitable for newbies.
|
||||
##
|
||||
## Before you go, check read around my blog!
|
||||
##
|
||||
## https://softwareshinobi.com
|
||||
##
|
||||
##
|
||||
|
||||
set -e;
|
||||
|
||||
set -x;
|
||||
|
||||
##
|
||||
## create user
|
||||
##
|
||||
|
||||
groupadd -g 4444 shinobi
|
||||
|
||||
useradd -u 4444 -g 4444 -rm -d /home/shinobi -s /bin/bash shinobi
|
||||
|
||||
##
|
||||
## set password
|
||||
##
|
||||
|
||||
echo 'shinobi:shinobi' | chpasswd
|
||||
|
||||
##
|
||||
## set up keys
|
||||
##
|
||||
|
||||
cp -r ssh/ /home/shinobi/.ssh
|
||||
|
||||
chmod -R 700 /home/shinobi/.ssh
|
||||
|
||||
chown -R shinobi: /home/shinobi/.ssh
|
||||
|
||||
##
|
||||
## restrict permissions on home
|
||||
##
|
||||
|
||||
#chmod -R 555 /home/shinobi/
|
||||
|
||||
#chmod -R 555 /tmp/
|
||||
Reference in New Issue
Block a user