Add Docker support with Dockerfile, docker-compose, and deployment documentation

This commit is contained in:
2025-12-07 23:47:07 +00:00
parent 4f954d9b15
commit 2ca35620d9
5 changed files with 244 additions and 0 deletions

25
docker-compose.yml Normal file
View File

@@ -0,0 +1,25 @@
version: '3.8'
services:
carplay-audio:
build: .
container_name: carplay-audio-server
restart: unless-stopped
ports:
- "4000:4000"
volumes:
# Mount your music library (change the left path to your music folder)
- /Volumes/Data/Music:/data/music:ro
# Persistent data (database, artwork, config)
- ./data/artwork:/app/artwork
- ./data/database:/app
- ./config.json:/app/config.json
environment:
- NODE_ENV=production
- PORT=4000
healthcheck:
test: ["CMD", "wget", "--quiet", "--tries=1", "--spider", "http://localhost:4000/health"]
interval: 30s
timeout: 10s
retries: 3
start_period: 40s