Getting Started

Running

tty-web --address 127.0.0.1 --port 9090 --shell /bin/zsh

Then open http://127.0.0.1:9090 in a browser.

CLI Flags

Every flag can also be set via an environment variable.

FlagEnvDefaultDescription
--addressTTY_WEB_ADDRESS127.0.0.1Listen address
--portTTY_WEB_PORT9090Listen port
--shellTTY_WEB_SHELL/bin/bashShell to spawn
--log-levelTTY_WEB_LOG_LEVELinfoLog level (trace, debug, info, warn, error)
--log-formatTTY_WEB_LOG_FORMATtextLog output format (text, json)
--pwdTTY_WEB_PWDinheritedWorking directory for new shell sessions
--scrollback-limitTTY_WEB_SCROLLBACK_LIMIT256Scrollback buffer size in KiB

Docker

Pre-built images are available for linux/amd64 and linux/arm64 in two variants:

VariantTagsDescription
minimallatest, <version>Single static binary (~5 MB), ideal for COPY --from
playgroundplayground, <version>-playgroundUbuntu with Python, Node, Go, Rust, Neovim

Minimal (default)

Scratch-based image with a single static binary. Use as a source for COPY --from:

COPY --from=ghcr.io/alviner/tty-web:latest /tty-web /usr/local/bin/tty-web

Playground

docker run --rm -p 9090:9090 ghcr.io/alviner/tty-web:playground

Override the default shell:

docker run --rm -p 9090:9090 ghcr.io/alviner/tty-web:playground \
  tty-web --shell /bin/sh