added client shell
This commit is contained in:
parent
83bf64bd39
commit
4d7087e7ca
16
root/usr/bin/client-shell
Normal file
16
root/usr/bin/client-shell
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
|
||||
if [ "$1" = "" ] ; then
|
||||
echo "Usage:"
|
||||
echo "$0 [hostname]"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
USER=$(db hosts getprop "$1" sshUser)
|
||||
|
||||
if [ "$USER" = "" ] ; then
|
||||
echo "Can't find an user for $1"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
/usr/bin/sudo -u amgmt /usr/bin/ssh -o StrictHostKeyChecking=no ${USER}\@${1} ${@:2}
|
Loading…
x
Reference in New Issue
Block a user