Run TallyHub in Docker on Raspberry Pi, Linux, or any container platform
One-command installation for Raspberry Pi and Linux:
curl -fsSL https://raw.githubusercontent.com/tallyhubpro/Tallyhub/main/install.sh | sudo bashUse the official prebuilt image from GitHub Container Registry:
1. Pull the latest image:
docker pull ghcr.io/tallyhubpro/tallyhub:latest2. Create required directories:
sudo mkdir -p /opt/tallyhub/logs /opt/tallyhub/public/firmware
sudo touch /opt/tallyhub/device-storage.json /opt/tallyhub/device-assignments.json3. Run the container:
docker run -d \
--name tallyhub \
--restart unless-stopped \
--network host \
-e NODE_ENV=production \
-e TZ=UTC \
-v /opt/tallyhub/device-storage.json:/app/device-storage.json \
-v /opt/tallyhub/device-assignments.json:/app/device-assignments.json \
-v /opt/tallyhub/logs:/app/logs \
-v /opt/tallyhub/public/firmware:/app/public/firmware:ro \
ghcr.io/tallyhubpro/tallyhub:latestUsing --network host is recommended on Raspberry Pi so mDNS/Bonjour and UDP device discovery work correctly.
If you can't use host networking, publish ports instead:
-p 3000:3000 -p 7411:7411/udpBuild and run TallyHub locally with Docker Compose:
1. Clone the repository:
git clone https://github.com/tallyhubpro/Tallyhub.git
cd Tallyhub/docker2. Start with Docker Compose:
docker compose up -d --build
docker compose logs -fdevice-storage.json - Device configurationsdevice-assignments.json - Camera assignmentslogs/ - Application logspublic/firmware - Custom firmware files (read-only)NODE_ENVdefault: developmentSet to 'production' for production deployments
LOG_LEVELdefault: infoLogging level: error, warn, info, debug
PORTdefault: 3000HTTP server port
TZdefault: UTCTimezone for logs (e.g., America/New_York)
GITHUB_TOKENdefault: noneOptional GitHub token for firmware downloads (higher rate limits)
DISABLE_MDNSdefault: falseSet to '1' to disable mDNS advertising
Optional but recommended for GitHub firmware downloads:
Add to your docker run command:
-e GITHUB_TOKEN=ghp_your_token_hereIf accessing a private GitHub Container Registry, authenticate first:
echo YOUR_GITHUB_TOKEN | docker login ghcr.io -u YOUR_USERNAME --password-stdindocker logs -f tallyhubdocker stop tallyhubdocker start tallyhubdocker restart tallyhubdocker pull ghcr.io/tallyhubpro/tallyhub:latest
docker stop tallyhub
docker rm tallyhub
# Then run the docker run command againdocker stats tallyhub--restart unless-stoppedPrevent log files from filling up disk space:
# Create a cron job to prune old logs
sudo crontab -e
# Add this line to run daily at 3 AM:
0 3 * * * find /opt/tallyhub/logs -name "*.log" -mtime +14 -deleteIf using a firewall, allow these ports:
# UFW (Ubuntu/Debian)
sudo ufw allow 3000/tcp
sudo ufw allow 7411/udp
# firewalld (CentOS/RHEL)
sudo firewall-cmd --add-port=3000/tcp --permanent
sudo firewall-cmd --add-port=7411/udp --permanent
sudo firewall-cmd --reload