Altare 容器 透传 做宝塔Web服务记录

系统选择 Debian 13

  1. 设置从不暂停:设置-> 空闲时暂停-> 停止-> 从未
  2. 安装缺失组件
    2.1 缺少 wget 执行命令
    apt update && apt install -y curl wget
    2.2 缺少 zip 执行命令
    apt update && apt install -y procps curl wget gawk file unzip
  3. 安装宝塔
if [ -f /usr/bin/curl ];then curl -sSO https://download.bt.cn/install/install_panel.sh;else wget -O install_panel.sh https://download.bt.cn/install/install_panel.sh;fi;bash install_panel.sh rU2tN9mZ
  1. 临时使用 frp客户端
cd /home/www/frpc
rm -rf frp*
wget https://github.com/fatedier/frp/releases/download/v0.72.0/frp_0.72.0_linux_amd64.tar.gz
tar -zxvf frp_0.72.0_linux_amd64.tar.gz
cd frp_0.72.0_linux_amd64

也可以用他们的文件管理功能,通过网页上传解压配置,然后再终端运行

frpc.toml服务端配置
先把配置写好(记得替换 serverAddr 和宝塔 localPort)

serverAddr = "填你的公网服务器IP"
serverPort = 容器端口
auth.method = "token"
auth.token = "yY4WB7nsJkGxdXv0"

name = "sandbox-bt"
type = "tcp"
localIP = "127.0.0.1"
localPort = "这里执行 bt default 拿到宝塔端口"
remotePort = 7002

name = "sandbox-ssh"
type = "tcp"
localIP = "127.0.0.1"
localPort = 26739
remotePort = 7003

测试启动

./frpc -c ./frpc.toml

宝塔面板

然后 http://你的公网服务器 IP:7002/你的宝塔安全入口

SSH 连接(连这个 Altare 沙箱)
ssh root@ 你的公网服务器 IP -p 7003

在SSH中管理宝塔使用 sudo bt 命令,不要直接使用bt,会报错

评论(0)

和大家一起交流

参与讨论

友善交流,认真表达

邮箱仅用于联系,不会公开
还没有评论

成为第一个参与讨论的人吧