mirror of
https://github.com/monlor/MIXBOX-ARCHIVE.git
synced 2026-03-10 23:41:27 +00:00
moxbox init
This commit is contained in:
9
apps/dropbear/config/banner
Normal file
9
apps/dropbear/config/banner
Normal file
@@ -0,0 +1,9 @@
|
||||
-----------------------------------------------------
|
||||
Welcome to MIXBOX!
|
||||
-----------------------------------------------------
|
||||
__ ______ __ ________ __ ____ ____ _ __
|
||||
/ / / / _/ / |/ / _/ |/ // __ )/ __ \ |/ /
|
||||
/ /_/ // / / /|_/ // / | // __ / / / / /
|
||||
/ __ // / / / / // / / |/ /_/ / /_/ / |
|
||||
/_/ /_/___/ /_/ /_/___//_/|_/_____/\____/_/|_|
|
||||
|
||||
8
apps/dropbear/config/dropbear.uci
Normal file
8
apps/dropbear/config/dropbear.uci
Normal file
@@ -0,0 +1,8 @@
|
||||
service="DropBear"
|
||||
appname="dropbear"
|
||||
needver="0.0.1"
|
||||
backupfiles="bin/dropbear,config/dropbear_dss_host_key,config/dropbear_rsa_host_key"
|
||||
supports="linux_arm,linux_mips"
|
||||
appinfo="移植小米的SSH功能到工具箱"
|
||||
newinfo="添加备份功能支持"
|
||||
version="0.0.2"
|
||||
26
apps/dropbear/config/mixbox.conf
Normal file
26
apps/dropbear/config/mixbox.conf
Normal file
@@ -0,0 +1,26 @@
|
||||
#------------------【DropBear】--------------------
|
||||
dropbear() {
|
||||
|
||||
eval `mbdb export dropbear`
|
||||
source "$(mbdb get mixbox.main.path)"/bin/base
|
||||
echo "********* $service ***********"
|
||||
echo "[${appinfo}]"
|
||||
echo "[仅支持小米路由器!]"
|
||||
readsh "启动${appname}服务[1/0] " "enable" "1"
|
||||
|
||||
if [ "$enable" == '1' ]; then
|
||||
# Scripts Here
|
||||
readsh "请输入${appname}端口号" "port" "1022"
|
||||
read -p "【慎重】是否启动时修改root用户密码[1/0]? " modify_passwd
|
||||
checkread $modify_passwd && mbdb set $appname.main.modify_passwd="$modify_passwd"
|
||||
if [ "$modify_passwd" = '1' ]; then
|
||||
readsh "请输入系统root用户密码" "rootpasswd"
|
||||
fi
|
||||
readsh "请输入${appname}外网访问配置[1/0]" "openport" "1"
|
||||
${mbroot}/apps/${appname}/scripts/${appname}.sh restart
|
||||
elif [ "$enable" = '0' ]; then
|
||||
${mbroot}/apps/${appname}/scripts/${appname}.sh stop
|
||||
fi
|
||||
|
||||
}
|
||||
#------------------【DropBear】--------------------
|
||||
Reference in New Issue
Block a user