以下内容是关于云计算学习路线源码框架笔记内容,下面是关于Shell版JumpServer开发的内容:
首先要有思路, 完善不足的地方
#!/usr/bin/env bash
#
Author: bavdu
Email: bavduer@163.com
Github: https://github.com/bavdu
Date: 2019//
while :
do
trap ':' INT EXIT TSTP TERM HUP
clear
cat <<-EOF
+-------------------------------------+
| JumpServer @Version1.0 |
+-------------------------------------+
| a. WebServer Apache. |
| b. MySQL Databases Server. |
| c. PHP Development Computer. |
| d. Quit |
+-------------------------------------+
EOF
read -p "Please input your jump to server's number: " computer
case $computer in
a)
ssh jumper@192.168.161.129
;;
b)
ssh jumper@192.168.161.130
;;
c)
ssh jumper@192.168.161.131
;;
d)
exit
;;
*)
printf "ERROR: Please redo your select!"
;;
esac
done