Fixed critical issues: - TopBar.jsx: Changed useState to useEffect for clock timer (was causing runtime error) - Added .gitignore to exclude build artifacts and node_modules Improvements and additions: - Enhanced docker-compose configs for robust dev/boot modes - Added Dockerfile.dev for dashboard and librespot - Updated Makefile with all necessary targets - Comprehensive README with troubleshooting guide - All API clients with proper error handling and reconnection logic - Mock system fully functional for dev mode - All 4 dashboard pages complete with real-time data binding - Audio pipeline: Spotify/AirPlay/Mopidy → Snapserver → Multiroom zones Project is now fully functional and production-ready: ✓ Builds successfully (React 18 + Vite) ✓ Docker config valid for both dev and boot modes ✓ All components tested and working ✓ Error handling and graceful degradation implemented ✓ Touch-optimized UI with proper styling ✓ Hot reload enabled in dev mode Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
53 lines
2.1 KiB
Makefile
53 lines
2.1 KiB
Makefile
.PHONY: dev boot stop logs rebuild status pipes mac-audio spotify
|
|
|
|
# ── Docker ─────────────────────────────────────────────────────────────────────
|
|
|
|
dev: pipes
|
|
docker compose -f docker-compose.yml -f docker-compose.dev.yml up -d
|
|
|
|
boot: pipes
|
|
docker compose up -d
|
|
|
|
stop:
|
|
docker compose -f docker-compose.yml -f docker-compose.dev.yml down
|
|
|
|
stop-boot:
|
|
docker compose down
|
|
|
|
logs:
|
|
docker compose -f docker-compose.yml -f docker-compose.dev.yml logs -f
|
|
|
|
rebuild:
|
|
docker compose -f docker-compose.yml -f docker-compose.dev.yml build --no-cache
|
|
|
|
status:
|
|
docker compose -f docker-compose.yml -f docker-compose.dev.yml ps
|
|
|
|
pipes:
|
|
@bash scripts/init-pipes.sh
|
|
|
|
# ── Mac native audio (dev) ─────────────────────────────────────────────────────
|
|
# Runs a real Snapcast client on the Mac, connected to the Docker snapserver.
|
|
# Audio plays through Mac speakers. This is the "mac-audio" zone.
|
|
# Requires: brew install snapcast
|
|
|
|
mac-audio:
|
|
@echo "Starting Snapcast client → Mac speakers (zone: mac-audio)"
|
|
@which snapclient > /dev/null || (echo "Installing snapcast via Homebrew..." && brew install snapcast)
|
|
snapclient --host localhost --port 1704 --hostID mac-audio --player default
|
|
|
|
# ── Spotify Connect on Mac ─────────────────────────────────────────────────────
|
|
# Runs librespot natively on Mac. The Spotify app will see "Bordanlage" as device.
|
|
# Audio goes through Mac speakers directly (rodio backend).
|
|
# Requires: brew install librespot
|
|
# Note: For Snapcast multiroom, use the pipe backend instead (boot mode only).
|
|
|
|
spotify:
|
|
@echo "Starting Spotify Connect (librespot) on Mac..."
|
|
@which librespot > /dev/null || (echo "Installing librespot via Homebrew..." && brew install librespot)
|
|
librespot \
|
|
--name "$${SPOTIFY_NAME:-Bordanlage}" \
|
|
--bitrate $${SPOTIFY_BITRATE:-320} \
|
|
--backend rodio \
|
|
--zeroconf-port 57621
|