0 在VPS上安装ZeroNet
tangdou1 edited this page 2020-04-15 16:23:27 +08:00
This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

以Debian系统举例其他系统可以用类似思路来安装。


(0.7.x版, python3)

  1. 通过putty或winscp等工具以root用户进入VPS

  2. 命令行输入以创建会话session1 apt-get update && apt-get install tmux && tmux new -s session1

  3. 在新的会话窗口中命令行输入以运行zeronet wget https://github.com/HelloZeroNet/ZeroNet/archive/py3/ZeroNet-py3.tar.gz && tar xvpfz ZeroNet-py3.tar.gz && cd ZeroNet-py3 && apt-get install python3-pip && python3 -m pip install -r requirements.txt && echo -e "[global]\nui_ip = 0.0.0.0\nui_port = 89" > zeronet.conf && python3 zeronet.py

  4. 在电脑或手机的浏览器中打开 http://你VPS的公网IP:89 要改变成其他端口还需修改2中的ui_port = 89


(0.6.5版, python2)

  1. 通过putty等工具以root用户进入vps
  2. 命令行输入 apt-get update
  3. 命令行输入 apt-get install tmux (安装tmux)
  4. 命令行输入 tmux new -s zeronet 开启新的tmux会话在会话中执行下面的命令
  5. 命令行输入 apt-get install msgpack-python python-gevent 安装zeronet所需插件
  6. 命令行输入 wget https://github.com/HelloZeroNet/ZeroNet/archive/master.tar.gz 下载0.6.5版本的zeronet包
  7. 命令行输入 tar xvpfz master.tar.gz (解压)
  8. 命令行输入 cd ZeroNet-master/plugins 定位到zeronet的插件文件夹
  9. 命令行输入 mv disabled-Bootstrapper Bootstrapper 开启zero协议的tracker功能-可选)
  10. 命令行输入 mv disabled-UiPassword UiPassword (开启密码保护功能)
  11. 命令行输入 cd .. (返回上一层文件夹)
  12. 命令行输入 vi zeronet.conf (创建并编辑配置文件)
  13. 文件内容写入(注意空格)(按下键盘i键进入编辑模式,在编辑模式中输入下面内容)
[global]
ui_ip = 0.0.0.0
ui_port = 8888
ui_password = woshimima

(随你喜欢改变端口号或密码)

  1. 保存zeronet.conf并退出按下Esc键退出编辑模式,输入:wq实现保存并退出)
  2. 命令行输入 python2 zeronet.py 开启zeronet
  3. 在电脑或手机的浏览器中打开 http://你VPS的公网IP:8888 ,进入密码页面,输入woshimima后正式进入。

如果是ipv6地址请用 http://[你VPS的公网IP]:8888 格式)

  1. 关闭你的putty等ssh软件就行啦。