gaze-so
v0.4.1
Published
Zero-config observability CLI - pipe logs and visualize instantly
Downloads
527
Maintainers
Readme
gaze-so CLI
Zero-config observability CLI - pipe logs and visualize instantly.
Quick Start
# Production (default)
echo '{"cpu": 45, "memory": 78}' | gaze
# Local development
echo '{"test": 123}' | gaze --local
# Custom ports
echo '{"data": 123}' | gaze --web http://localhost:3000 --socket http://localhost:8080Installation
npm install -g gaze-soUsage
Pipe any output to gaze:
# JSON logs
echo '{"cpu": 45, "memory": 78}' | gaze
# Script output
python script.py | gaze
node server.js | gaze
docker logs -f | gaze
# Reuse session
echo '{"more": "data"}' | gaze --session-id gaze-abc123Options
| Flag | Description | Example |
|------|-------------|---------|
| -s, --session-id <id> | Reuse existing session | gaze --session-id gaze-abc123 |
| -l, --local | Use localhost (web: 3000, socket: 3001) | gaze --local |
| --web <url> | Web server URL | gaze --web http://localhost:3000 |
| --socket <url> | Socket server URL | gaze --socket http://localhost:8080 |
| --server <url> | Shorthand for --web (auto-derives socket) | gaze --server http://localhost:3000 |
Server Configuration
The CLI automatically derives the socket URL from the web URL, but you can override it:
# Auto-derive socket (localhost:3000 → localhost:3001)
gaze --web http://localhost:3000
# Explicit socket URL
gaze --web http://localhost:3000 --socket http://localhost:8080
# Production (auto-derives socket.gaze.so)
gaze --server https://gaze.so
# Custom domain
gaze --web https://staging.gaze.so --socket https://socket-staging.gaze.soPriority Order
- Flags (
--web,--socket,--local,--server) - Environment variables (
GAZE_WEB_URL,GAZE_SOCKET_URL) - Production defaults (
https://gaze.so,https://socket.gaze.so)
Environment Variables
export GAZE_WEB_URL=http://localhost:3000
export GAZE_SOCKET_URL=http://localhost:8080Examples
# Production (default)
echo '{"data": 123}' | gaze
# Quick localhost
echo '{"data": 123}' | gaze --local
# Custom web server, auto socket
echo '{"data": 123}' | gaze --server http://localhost:3000
# Both custom
echo '{"data": 123}' | gaze --web http://localhost:3000 --socket http://localhost:8080
# Staging
echo '{"data": 123}' | gaze --server https://staging.gaze.soLicense
MIT
