Coder Social home page Coder Social logo

open-ip-kvm's Introduction

把原作者写死的端口改成自动获取真实端口。这样做了ddns和端口转发的就能用你的ip端口访问了。配合caddy做代理鉴权。可以实现账号密码访问,保证了安全性

Open IP-KVM

This project provides an open-source IP-KVM solution.

Related article:

DIY 一个运维神器 Open IP-KVM

English Version By Google Translate

What is IP-KVM

KVM Over IP (IP-KVM) is a hardware based solution for remote access to your computer or server.

The unit plugs into the Keyboard, Video and Mouse ports of a computer or server and transmits those to a connected user through a network.

IP-KVM vs RD software(VNC/RDP/TeamViewer)

  • RD software requires a working OS, and must be pre-configured. It often fails in an emergency situation
  • IP-KVM is out-of-band, so it can be used to install OS, setup BIOS or fix low-level issues

Features

Demo Video

  • Web browser as client
  • 1080P 30fps video stream
  • Full mouse & keyboard support
  • UI Indicator
  • Remote Paste: Input ASCII sequence

screenshot

System Diagram

diagram

Hardware Requirements

  • HDMI-USB capture device
    • Recommendation: MS2109 based devices link
    • Input: Up to 4K 30FPS
    • Output: Up to 1080P 30FPS @ MJPEG
  • Linux single-board computer
    • Recommendation: Phicomm N1, Raspberry Pi 4 or other models,
    • Recent linux kernel
    • 2+ USB ports
  • Arduino Leonardo link
    • Emulate HID (mouse and keyboard)
  • Optional
    • USB-to-TTL Adapter
      • If linux sbc has no built-in serial port
      • Recommendation: PL2303HX
    • USB Wi-Fi Adapter
      • If linux sbc has no built-in Wi-Fi

Deploy and Run

1. Prepare Arduino Leonardo

Upload program
  1. Download and install Arduino IDE on your PC.
  2. Connect leonardo to PC via USB
  3. Download arduino code file virt-hid-arduino.ino, Open it with Arduino IDE, then click Sketch/Upload (Ctrl + U)
  4. Disconnect leonardo USB
Reference: How to connect serial port

image

serial

2. Prepare Linux SBC

SSH to linux SBC with your pc.

Deploy App and Dependency on Linux SBC
Connect IO and edit config
  • Connect IO
    • HDMI-USB capture device via USB
    • Arduino Leonardo via native serial port or USB-TTL adapter
  • Edit open-ip-kvm/server/config.json
    • mjpg_streamer.device: path of HDMI-USB capture device
    • serialport: path of serial port

3. Run

  1. Connect HDMI output of target computer to HDMI-USB capture device
  2. Connect target computer to leonardo via USB
  3. Run cd open-ip-kvm && npm run start on linux SBC
  4. Turn on target computer
  5. Open http://[IP of Linux SBC]:8000 in web browser

How to control

  • Mouse
    • Click anywhere to enter pointer capture mode
    • Press ESC to exit
  • Keyboard
    • Press Enter to enter key capture mode
    • press Shift + ESC to exit

License

MIT

Credits

mjpg_streamer

For production environment, use Pi-KVM

open-ip-kvm's People

Contributors

hejunv avatar nihiue avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.