Git Product home page Git Product logo

openterminal's Introduction

OpenTerminal

An online terminal and communal text buffer

openterminal thumbnail image

how it works

a simple static web server pushes out the html, css and javascript needed to make this function well and look pretty on client devices. from there, clients connect back to the server's websocket, which they then exchange keystroke information with, back and forth, all passing through the server's own saved buffer. (if you refresh the page, everything's still there!)

wouldn't this be really easy to grief?

yes!

jokes aside- while i do absolutely see how an open, self-moderated text buffer is hilariously easy to grief, i could also imagine users taking the concept and pushing it quite a bit further than what i'm doing here. who knows? maybe a anti-spam bot could come in, read through the buffer for any nefarious material, and backpedal through the buffer just enough to remove it, before replacing the otherwise above-board text from memory.

...or maybe it'll just become a garbage-posting haven. regardless, it's a fun little idea, so i made it anyway.

hosting

  • git clone this repo and cd into it
  • npm ci to install dependencies
  • npm run start, and you should be good to do!

alternatively, you can git clone this repo and docker build a container if you like. we do not yet have official openterminal images on a public repo, sorry!

OpenTerminal also makes use of environment variables for server hosts who want a bit more control of their setup:

  • OPENTERM_HOST - the address to bind OpenTerminal's http and websocket server. (default 0.0.0.0)
  • OPENTERM_POST - the port to bind OpenTerminal's http and websocket server. (default 8080)
  • OPENTERM_TRUSTED_PROXIES - a comma-separated list of addresses to check for X-Forwarded-For headers from. handy if you run OpenTerminal behind a reverse proxy! (default none, example "127.0.0.1,192.168.0.100")

roadmap

  • rewrite backend in go/rust (me no like javascript raaaahhh)
  • master server (anyone can host a channel and post to the MS)

"maybe" roadmap

  • channel logs (for recovery in the event of a crash, as an optional feature)

openterminal's People

Contributors

arimelody avatar slinthn avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

Forkers

slinthn

openterminal's Issues

Server crash on directory read

Requesting a directory as a file in the HTTP request causes a read attempt on a directory, which crashes the server.

Downloading version 1.0.3 of OpenTerminal and running the node server, simply run the command:
curl -k -v https://127.0.0.1:8080/styles

image

Ignore the extra output in the node terminal, that is just testing by me.

Backspace breaks emojis

image

Using backspace on emojis like 🤩 causes them to become an unknown Unicode character, in this case � instead of deleting them. Might be because you're working with bytes instead of graphemes?

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.