Network Deployment Guide
Deploy EmbyTok on your local network so multiple devices can access your video library through a single server instance. This guide covers Docker deployment, network configuration, and the folder server mode for serving local files.Overview
EmbyTok can run as a network service that provides:- Web Interface: Static site serving the EmbyTok UI
- Folder Server API: REST API for browsing and streaming local video files
- Multi-Device Access: Any device on your network can connect via browser
This deployment mode is ideal for home networks where you want to share a local video library across phones, tablets, and computers without setting up a full media server like Emby or Plex.
Deployment Options
Option 1: Docker Compose (Recommended)
Best for: Production deployments on NAS, Linux servers, or desktopsOption 2: Docker Run
Best for: Quick testing or single-container deploymentsOption 3: Node.js Direct
Best for: Development or systems without DockerPrerequisites
- Docker and Docker Compose installed (for Docker deployment)
- Node.js 14+ and npm (for Node.js deployment)
- A folder containing video files you want to serve
- Local network with devices on the same subnet
Docker Compose Deployment
Step 1: Prepare Media Folder
Create or identify a folder with your videos:Step 2: Create docker-compose.yml
From the repository’sdocker-compose.yml:1-22:
Step 3: Configure Environment Variables
Create a.env file in the same directory:
Step 4: Create Config File
Create an empty config file for persistence:Step 5: Start the Container
Step 6: Access from Network
Open a browser on any device on your network and navigate to:Docker Run Deployment
For a quick single-command deployment:Building the Image First
If you have the source code:Node.js Direct Deployment
Without Docker, you can run EmbyTok using Node.js directly.
The server will output network URLs:
Environment Variables Reference
From the Docker configuration and README:| Variable | Default | Description |
|---|---|---|
HOST | 0.0.0.0 | Network interface to bind to. Use 0.0.0.0 for all interfaces |
PORT | 5176 | Port to listen on |
SERVE_WEB | true | Whether to serve the static web UI |
WEB_ROOT | dist | Path to static files (use /app/dist in Docker) |
LAN_CONFIG_FILE | ./lan-media-config.json | Path to persistent config file |
MEDIA_ROOT | - | Default media folder for initial service creation |
BROWSE_ROOTS | - | Comma-separated list of browsable root directories |
MEDIA_ROOT vs BROWSE_ROOTS
MEDIA_ROOT: Used only on first startup to create a default folder service. Optional. Example:Configuring Folder Services
After deployment, configure which folders to serve through the admin panel.Accessing Admin Panel
Browse and Select Folder
Use the file browser to navigate to your video folder within the
BROWSE_ROOTS paths.Multiple Folder Services
You can create multiple services for different video collections:Connecting Clients
Once the server is running and configured, connect from any device:Select 'Folder Service' Mode
Click the cyan Folder Service button on the login page (from
Login.tsx:365-371).Select Service Name
Choose from the dropdown list of configured services (e.g., “Vertical Videos”).From
Login.tsx:420-435, the service list is fetched from:Folder Server API
The folder server provides several REST endpoints:Health Check
List Services
List Libraries
Fetch Videos
FromFolderServerClient.ts:97-126:
Stream Video
Network Configuration
Finding Your Server IP
Linux/Mac:192.168.x.x or 10.0.x.x).
Firewall Configuration
Ensure port 5176 (or your chosen port) is open: Linux (ufw):- Windows Defender Firewall → Advanced Settings
- Inbound Rules → New Rule
- Port → TCP → 5176
- Allow the connection
Testing Connectivity
From another device on the network:NAS Deployment (Synology, QNAP, etc.)
Special considerations for NAS devices are documented indocs/DOCKER_NAS.md.
Quick NAS Setup
Pull or Build Image
If your NAS is amd64, pull from GHCR:Or build locally (if you have source code on NAS):
Common NAS Pitfalls
FromDOCKER_NAS.md:36-51:
Cross-Architecture Deployment
If you’re building on a Mac (ARM64) but deploying to a NAS (AMD64):Using GHCR Multi-Arch Images
The repository auto-builds multi-architecture images on push:Building Locally for Different Architecture
FromDOCKER_NAS.md:124-132:
Advanced: HTTPS/SSL Setup
For secure access, use a reverse proxy like Nginx or Caddy.Example: Caddy Reverse Proxy
https://embytok.local on your LAN.
Example: Nginx Reverse Proxy
Performance Optimization
Video Format Recommendations
- Codec: H.264 (AVC) for maximum browser compatibility
- Container: MP4
- Resolution: 1080x1920 for vertical videos
- Bitrate: 5-10 Mbps for good quality without excessive file size
Network Performance
- Use wired Ethernet for the server when possible
- Wi-Fi 5 (802.11ac) or better for client devices
- Keep server and clients on same subnet to avoid routing overhead
- Consider network quality when setting video bitrates
Scaling for Many Users
- CPU: Video streaming is mostly I/O bound, but thumbnail generation uses CPU
- RAM: Minimal (512MB should suffice for most deployments)
- Storage I/O: SSD recommended for faster directory scanning and thumbnail loading
- Network: Gigabit Ethernet recommended if serving 5+ simultaneous streams
Troubleshooting
Container Won’t Start
Port already in use
Port already in use
Check if another service is using port 5176:Change to a different port in
.env or docker-compose.yml.Permission denied on volume mount
Permission denied on volume mount
Ensure Docker has permission to read your media folder:On NAS devices, add Docker to appropriate groups.
Videos Not Appearing
- Check admin panel: Visit
/adminand verify services are configured - Verify API: Test
http://server:5176/api/folder/videos?feedType=latest&serviceId=<id> - Check container logs:
docker compose logs embytok - Verify paths: Ensure
MEDIA_ROOTandBROWSE_ROOTSpoint to/mediainside container
Slow Performance
- Enable browser caching: Ensure static assets are cached
- Check network speed: Use EmbyTok’s built-in speed test
- Monitor container resources:
docker stats embytok - Optimize video files: Re-encode large files to lower bitrates
Next Steps
- Configure Emby integration for server-based media libraries
- Set up Plex integration as an alternative
- Learn about local folder browsing for offline clients
- Build the iOS native app for native mobile playback