Changes
🚀 Feature Release - Fast Serialization & Port Configuration
Overview
This patch stabilizes API serialization by migrating to Zod‑driven Fastify serializers and fixes a Docker health check issue caused by incorrect internal port binding. It also hardens SPA routing/auth flows and aligns several schemas with OpenAPI for clearer errors and safer defaults.
Key Updates
Fastify + Zod Serializers
- Switches to
fastify-zod-openapiwhich generates proper JSON schemas, enabling Fastify's fast-json-stringify optimizations for faster API responses. - Normalizes 204 responses and tightens ID/URL validation across routes.
Docker Health Check & Ports
- New
listenPortsetting allows changing the internal port the app binds to (default 3003). - Separates external
port(for webhook URLs) from internallistenPort(what the container listens on). - Docker HEALTHCHECK now correctly uses the internal port.
SPA Routing & Error Handling
- Base‑path aware SPA catch‑all with segment‑safe stripping (
/appno longer matches/application). - HTML‑only SPA responses; API/static paths return 404 (no HTML fallthrough).
- Centralized error handling produces consistent, schema‑aligned errors.
Breaking Changes (if applicable)
- None intended. Stricter schema validation/coercion may surface 400s for previously accepted invalid inputs (IDs, URLs). Review client/automation flows if you see new 400s.
Technical Changes
Serializer/Validator
- Moves Zod compilers to app bootstrap; standardizes route schemas for OpenAPI.
Schemas
- Positive‑int constraints for instance IDs; http(s)‑only guards for specific URLs.
- Config update schema
.strict()to reject unknown/protected fields.
Logging/Streams
- Small SSE/log stream safety improvements (keep‑alive and listener cleanup).
Migration & Compatibility
Docker users
# docker-compose.yml
ports:
- "3063:3003" # external:internal
# .env file
port=3063 # external port for webhook URLs
listenPort=3003 # internal port (useful for bare-metal users to change app port)Manual installation
git pull origin master
npm install
npm run build
npm run start:prodNo database migrations in this patch.
Full Changelog: v0.8.0...v0.8.1
Docker Image: lakker/pulsarr:0.8.1
- Feature: Fast Serialization & Port Configuration (#812) @jamcalli
- Feature/zod serialization improvements (#811) @jamcalli
Docker
docker pull lakker/pulsarr:0.8.1