Self-hosted video for VOD, live, sharing, and API access. Upload and transcode, go live from OBS, share with a password or embed. Your box, your files.
Runs bitbyte3.com's video stack in production. 120 TB+ encoded media since 2022. The public repo is that codebase cleaned up for self-hosting. We still ship internal patches on our install first.
Worth reading before you commit hardware:
- HEVC/H.265 live is flaky on CPU and GPU. Use H.264 for live for now.
- Aimed at personal/small-team self-hosting, not replacing Akamai.
Share: public links, password shares, email invites, embeds. Create from the video page or Client API.
Live: RTMP from OBS, HLS/DASH while live, optional recording to VOD. See live streaming docs.
VOD: multi-bitrate HLS/DASH, thumbnails/sprites, Whisper subtitles, Vimeo/Drive/Dropbox imports, collections.
Security: domain/geo rules, signed Edge delivery with AES-128, API keys on /api/client/v1/*.
| Component | Repository | Role |
|---|---|---|
| zaynin-engine | github.com/Muntader/zaynin-engine | bin/media-vod + bin/media-live |
| zaynin-manifest | github.com/Muntader/zaynin-manifest | bin/manifest |
| nixstream-edge | github.com/muntader/nixstream-edge | Signed media origin + AES-128 decrypt; vendored as bin/nixstream-edge |
| snapencode-player | github.com/Muntader/snapencode-player | Upstream of bundled nixstream-player |
Docker bundles media-vod, media-live, manifest, and nixstream-edge, all prebuilt binaries under bin/, so nixstream/ alone is enough to run ./install.sh --build. No need for the sibling nixstream-edge/ checkout unless you're rebuilding it from source (scripts/build-edge.sh).
flowchart LR
Browser --> Nginx --> Laravel
Laravel --> MySQL
Laravel --> Redis
Queue --> MediaVOD["media-vod (zaynin-engine)"]
MediaVOD --> Storage[(Local / S3 / R2)]
Browser --> Edge["nixstream-edge"]
Edge --> Storage
OBS --> MediaLive["media-live (zaynin-engine)"]
MediaLive --> Storage
| Service | Role |
|---|---|
| Laravel app | Admin panel, Client API, job dispatch |
| Queue workers | VOD encoding (media-vod), Whisper transcripts |
media-live |
RTMP ingest and live packaging |
nixstream-edge |
Signed playback URLs, AES-128 decrypt at edge |
| MySQL / Redis | Data, cache, sessions, queues |
Monorepo layout: nixstream/ (Laravel app), nixstream-edge/ (Go origin), nixstream-docs/ (docs site).
Requirements: Docker 24+, Docker Compose v2, 8 GB RAM, 4+ CPU cores.
One command (clone + install):
curl -fsSL https://raw.githubusercontent.com/Muntader/nixstream/main/nixstream/scripts/bootstrap.sh | bash -s -- -yFrom a local clone:
git clone https://github.com/Muntader/nixstream.git
cd nixstream/nixstream
./install.shOpen http://localhost. Admin email is in .env as ADMIN_EMAIL; the password is generated once at install, printed by install.sh, and never stored in .env.
HTTPS with Let's Encrypt:
./install.sh --ssl your-domain.comPoint DNS A records for your-domain.com and edge.your-domain.com at the host before running.
Dev mode with Vite HMR:
./install.sh --devGPU / CUDA: default Docker images are CPU-only FFmpeg and Whisper. NVENC works if you wire GPU FFmpeg on the host; stock Compose does not enable it. See GPU encoding.
More: nixstream.bitbyte3.com/docs. Start with Docker install.
| Key | Purpose |
|---|---|
media_cli_path |
Path to bin/media-vod |
WHISPER_CLI_PATH |
Path to whisper-cli |
MEDIA_SERVER_HOST |
Live streaming API URL |
EDGE_BASE_URL |
Public nixstream-edge URL (player-reachable) |
Queue video-encoding |
Long-running transcode jobs |
After changing permissions in config/acl.php, run php artisan permission:cache-reset.
npm run dev
php artisan route:list --path=api
./vendor/bin/phpunit- Admin login: Sanctum (
/api/login). Share pages and embeds are public. - Shares per video: public, password, or email invite.
- Live recording: toggle Save recording as VOD on the stream.
- Client API:
/api/client/v1/*, keys from Settings > General. - Playback URLs come from nixstream-edge, not
public/storage. Local disk without Edge won't do signed/AES playback. - Stock Compose is CPU-only FFmpeg. NVENC needs your own GPU FFmpeg setup.
- Docs: nixstream.bitbyte3.com
- Custom work: dev@bitbyte3.com
MIT. See LICENSE.
