[Linux]Ubuntu noVNC使用

又到了逛大型程序员交友 网站的时间了,今天你准备好了吗。

今天要推荐的一个有趣的项目是noVNC

setup好以后是这个样子的,可以在浏览器登陆vnc,不需要再安装一个vnc client.

setup的过程比较简单,分为以下几步:

1. vncserver

novnc基于vncserver,所以需要先把vncserver的环境搭建好,最后的目标就是在命令行敲vncserver的时候他会提示在:1或者:5901创建成功。

shell 复制代码
sudo apt-get install tightvncserver

这里不展开,网上有大量的教程。

这里要注意记住设置的vncserver的password,下面会用到。

2. novnc

Use the novnc_proxy script to automatically download and start websockify, which includes a mini-webserver and the WebSockets proxy. The --vnc option is used to specify the location of a running VNC server:

shell 复制代码
git clone https://github.com/novnc/noVNC.git
cd noVNC
./utils/novnc_proxy --vnc localhost:5901 --listen localhost:6081

这时你应该可以看到这样的输出:

复制代码
Using local websockify at /home/xxx/projects/noVNC/utils/websockify/run
Starting webserver and WebSockets proxy on host localhost port 6081
WebSocket server settings:
  - Listen on localhost:6081
  - Web server. Web root: /home/xxx/projects/noVNC
  - SSL/TLS support
  - proxying from localhost:6081 to localhost:5901


Navigate to this URL:

    http://localhost:6081/vnc.html?host=localhost&port=6081

Press Ctrl-C to exit

这时,把上面那个URL copy到浏览器里打开然后点connect输入你的vncserver密码就可以了,实际用下来和vnc client没啥差别。

相关推荐
崔小汤呀8 分钟前
最全的docker安装笔记,包含CentOS和Ubuntu
linux·后端
何中应21 分钟前
vi编辑器使用
linux·后端·操作系统
何中应21 分钟前
Linux进程无法被kill
linux·后端·操作系统
何中应23 分钟前
rm-rf /命令操作介绍
linux·后端·操作系统
Bigger30 分钟前
为什么你的 Git 提交需要签名?—— Git Commit Signing 完全指南
git·开源·github
何中应35 分钟前
Linux常用命令
linux·操作系统
葛立国41 分钟前
从 / 和 /dev 说起:Linux 文件系统与挂载点一文理清
linux
DianSan_ERP15 小时前
电商API接口全链路监控:构建坚不可摧的线上运维防线
大数据·运维·网络·人工智能·git·servlet
哇哈哈202116 小时前
信号量和信号
linux·c++
呉師傅16 小时前
火狐浏览器报错配置文件缺失如何解决#操作技巧#
运维·网络·windows·电脑