时光2020

  博客园  :: 首页  :: 新随笔  :: 联系 :: 订阅 订阅  :: 管理

手机安装termux,安装OpenSSL设置登录启动sshd,安装nps启动  并安装anLinux在并安装Ubuntu
换源 termux-change-repo
获得手机存储权限termux-setup-storage
pkg install openssh -y
pkg install vim curl wget tree net-tools -y



vi /data/data/com.termux/files/usr/etc/termux-login.sh




##
## This script is sourced by /data/data/com.termux/files/usr/bin/login before executing shell.
##
if pgrep sshd > /dev/null
then
  echo 'sshd is stared!'
else
  sshd
  echo 'start sshd!'
fi

if pgrep nps > ~/npslog.log
then
  echo 'nps is stared!'
else
  nohup nps >> ~/npslog.log 2>&1 &
  echo 'start nps!'
fi

 

 

chmod u+x


使用anLinux安装Ubuntu安装Ubuntu桌面

完成后调整vnc分辨率

root@localhost:/usr/local/bin# cat vncserver-start
export USER=root
export HOME=/root

vncserver -geometry 1920x1080 -depth 24 -name remote-desktop :1



自启动如需使用服务管理需要安装  pkg install termux-services -y
详情请看
https://blog.csdn.net/YiBYiH/article/details/127294017

posted on 2024-01-31 13:05  时光2020  阅读(245)  评论(0)    收藏  举报