Skip to content

bankosegger/thermobanko

Repository files navigation

Thermobanko

A tiny web UI + server for sending short text messages to a thermal receipt printer. The name comes from "Thermo" (thermal printer) + "banko" (me)

Why? Fast way to print short receipts, notes or status lines from any device on your LAN (or even the internet, if you set up port forwarding and have no fear).

Here you can see my Thermobanko setup:

Thermobanko Setup

Thermobanko — a tiny web UI for sending short text to a thermal receipt printer

Quick start

  1. Install dependencies
npm install
  1. Start the server
node server.js
  1. Open in a browser

http://localhost:3000

What you'll see

  • A simple page showing your IP and a "Print" action. Each print increments a local counter.

Files of interest

  • server.js – Node server and API endpoints
  • app.js / print.js / cprint.js – client + print helpers
  • data/ – local JSON files (counters, history, aliases)
  • default_printer.js – default printer abstraction

Notes

  • This repo has been sanitized for sharing; local data/ files contain no personal information.
  • Configure or replace the printer backend if you want to connect a real device.

License

  • MIT (see LICENSE)

Docker & nginx

  • Why included

    • Docker provides an easy environment to run Thermobanko without installing Node and its dependencies on the host.
    • nginx is included to show how you might reverse-proxy the app, serve static assets efficiently, or place the app behind TLS and a single public endpoint.
  • How the Docker setup works

    • A Dockerfile in the repository builds a small Node image that contains the app and its dependencies.
    • docker-compose.yaml (if present) wires the Node service and an nginx container together so nginx can proxy HTTP requests to the Node server.

    Quick run (Docker):

     # build and start services using docker-compose
     docker compose up --build
  • How the nginx setup works

    • nginx/nginx.conf shows a simple reverse-proxy configuration. nginx listens on port 80 (or 443 if TLS configured) and forwards requests to the Node app running on the internal network.
    • This reduces exposure of the Node app, improves static file serving, and makes it straightforward to add TLS or additional routing rules.

    Quick run (nginx + Node locally):

     # Start the Node app locally
     node server.js
    
     # Start nginx (example assumes nginx is installed on host)
     sudo nginx -c $(pwd)/nginx/nginx.conf

    Notes:

    • If you use the included Docker compose setup, nginx runs in a container and you don't need to install nginx on the host.
    • Adjust ports in docker-compose.yaml or nginx/nginx.conf to avoid conflicts with other services.

About

I bought a Thermoprinter and now my friends can send me printed messages! So it is like the (Austrian) Postal Service, but cheaper!

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors