推荐学习书目
› Learn Python the Hard Way
Python Sites
› PyPI - Python Package Index
› http://diveintopython.org/toc/index.html
› Pocoo
值得关注的项目
› PyPy
› Celery
› Jinja2
› Read the Docs
› gevent
› pyenv
› virtualenv
› Stackless Python
› Beautiful Soup
› 结巴中文分词
› Green Unicorn
› Sentry
› Shovel
› Pyflakes
› pytest
Python 编程
› pep8 Checker
Styles
› PEP 8
› Google Python Style Guide
› Code Style from The Hitchhiker's Guide
xsank
V2EX  ›  Python

基于 tornado 的 web ssh 项目

  •  1
     
  •   xsank · Sep 23, 2015 · 4404 views
    This topic created in 4065 days ago, the information mentioned may be changed or developed.

    原文地址: http://xsank.com/?p=1518

    上次有幸观看梁胜大牛的技术分享,其中一个演示是浏览器中显示了一个 linux 终端并登录管理 server ,于是决定自己实现一个

    github 中有一个项目 gateone 实现了此功能,本来想学习一下,但是考虑到代码实在过多就放弃了,下面说下自己的实现。

    项目地址: https://github.com/xsank/webssh

    欢迎大家拍砖

    1.终端展示

    使用了 github 开源项目 term.js ,这是个很赞的项目,因为在刚开始写的时候你会发现 linux 返回的很多内容带有特殊字符,需要穷举处理,而这里正好有一个框架帮你做了这些复杂的操作

    2.长连接

    这里使用了 websocket ,因为类似 top 这样的监控命令需要服务器定时推送

    3.ssh 登录

    使用第三方 paramiko 库来支持 server 的加密登录

    kslr
    kslr
    Sep 23, 2015
    1
    很棒
    PythonAnswer
    PythonAnswer
    Sep 23, 2015
    2
    有唐伯虎也有 vim
    xsank
    xsank
    OP
    Sep 23, 2015
    3
    欢迎各位关注项目,有任何问题请告诉我,谢谢~
    zeuss
    zeuss
    Sep 23, 2015❤️1
    4
    给楼主点赞,已 star + follow
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Privacy   ·   Solana   ·   979 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 29ms · UTC 22:29 · PVG 06:29 · LAX 14:29 · JFK 17:29
    ♥ Do have faith in what you're doing.