screentinker/brightsign/server
screentinker 0b063cd415
Some checks are pending
CI / Unit tests (node --test) (push) Waiting to run
CI / OpenAPI spec lint (push) Waiting to run
CI / Android unit tests (Kotlin schedule evaluator vectors) (push) Waiting to run
CI / Licence gate + SBOM (production deps) (push) Waiting to run
CI / Boot smoke + version check (push) Waiting to run
Make the on-device server opt-in, and stop the status port answering the LAN (#291)
A fleet gets one package, and exactly one box per site should host the server.
Defaulting to on would mean every player that ever received this package
started listening on 8181, and the mistake would stay invisible until two of
them fought over the same displays.

st-config.json on the storage root, {"server": 1}, switches it on. Absent,
unreadable, unparseable, or anything other than an affirmative value leaves it
off - there is no reading of a broken config file that should end with a
device deciding to host a server. It sits at the root rather than in data/
because that is where an operator drops it over the DWS, and autozip never
writes it, so a re-provision cannot silently flip a site either way. The
package ships st-config.example.json, never st-config.json, for the same
reason.

With the server off, NOTHING listens: roNodeJs is never created, so there is
no 8181 and no 8182. The page is told through its URL rather than discovering
it, because "nothing is answering" would otherwise render as a fault and send
someone looking for a server that was never meant to exist. It now has a
fourth state that says so and offers the one line of JSON that changes it.

Separately: the status listener was bound to every interface, so anything on
the customer's LAN could read the install log, disk usage, the device's own
address and a tail of the server's console - that last one carries whatever
the server printed most recently. Its only consumer is a page on the same
device. Now 127.0.0.1 only, confirmed against /proc/net/tcp rather than by
probing, after a first attempt at verifying it fell back to loopback and
reported that as the LAN result.


Claude-Session: https://claude.ai/code/session_014kfhrUPit5MCqxeTQyqr56

Co-authored-by: Dan Walters <dan.walters@bytetinker.net>
Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
2026-08-18 16:32:37 -05:00
..
autorun.brs Make the on-device server opt-in, and stop the status port answering the LAN (#291) 2026-08-18 16:32:37 -05:00
bs-payload-install.js Run the ScreenTinker server on the player it serves (#288) 2026-08-18 15:16:09 -05:00
bs-server-boot.js Make the on-device server opt-in, and stop the status port answering the LAN (#291) 2026-08-18 16:32:37 -05:00
node-server.html Make the on-device server opt-in, and stop the status port answering the LAN (#291) 2026-08-18 16:32:37 -05:00
server.env.example Run the ScreenTinker server on the player it serves (#288) 2026-08-18 15:16:09 -05:00
st-config.example.json Make the on-device server opt-in, and stop the status port answering the LAN (#291) 2026-08-18 16:32:37 -05:00