Docker Web UI
Browser-based metadata injection for MP4/MOV files, running in Docker. Uses the
same spatial library as the command-line tool and desktop GUI.
Features
- Web interface: drag-and-drop upload, progress indicator, download links
- Stereoscopic modes: none, left-right, or top-bottom
- In-place inject: rewrite metadata in the uploaded file when the layout supports it (default on; avoids a second full copy on disk)
- Spatial audio: inject ambisonics metadata when the source track is compatible
- Large files: up to 4 GB per upload by default (
MAX_UPLOAD_BYTES); mount a host directory to process files without uploading through the browser - Headless: no X11 or Tkinter in the container
Prerequisites
For quick one-off tagging without Docker, use the browser demo or download a CLI binary.
Build and run
git clone https://github.com/Nandan-18/spatialtag.git
cd spatialtag
docker build -t spatialtag-web -f docker/Dockerfile .
mkdir -p data
docker run -p 5000:5000 \
--name spatialtag \
-v "$(pwd)/data:/app/uploads" \
spatialtag-web
Open http://localhost:5000.
PowerShell (volume mount):
mkdir data -ErrorAction SilentlyContinue
docker run -p 5000:5000 `
--name spatialtag `
-v ${PWD}\data:/app/uploads `
spatialtag-web
Working with very large files
For multi-GB sources, skip the browser upload and bind-mount the directory that already contains your videos:
docker run -p 5000:5000 \
-v /path/to/your/videos:/app/uploads \
spatialtag-web
Copy or move files into that folder, then use the web UI to inject (with Inject in place enabled). Alternatively, use a CLI binary on the host:
spatialtag -I --vr180 /path/to/your/videos/file.mp4
Usage
- Drag and drop
.mp4or.movfiles (or click to browse). - Choose options:
- Spherical (360): equirectangular video metadata
- Stereo mode: none, left-right, or top-bottom
- Inject in place: overwrite the uploaded file when supported (recommended for large files on a mounted volume)
- Spatial audio: ambisonics metadata (requires a compatible track)
- Click Inject Metadata.
- Download results from the page, or read them from your mounted
data/(or custom) folder.
Troubleshooting
"File not found" or missing output
Ensure the volume mount is set: -v ...:/app/uploads. All uploads and in-place
writes go to that path inside the container.
Container name already in use
docker rm -f spatialtag
In-place inject failed
Some files have moov before mdat; those cannot be updated in place. Disable
Inject in place in the UI (creates injected_<filename>) or use the CLI
with separate input/output paths.
Security notes
- Filenames are sanitized and path traversal (
..,/) is rejected. - Do not expose this service on a public network without authentication; it accepts file uploads and writes to disk.
- Intended for local or trusted LAN use.