ByteDown
A self-hosted image optimization service with an independent API and a browser workshop.
Self-hosted portfolio project / trusted single-operator scope
Problem & audience
Preparing images for web delivery involves preserving source files, choosing formats and producing multiple sizes. ByteDown makes that workflow available through an asynchronous service rather than tying it to a specific CMS.
An individual operator or trusted server-side application that needs JPEG/PNG optimization and responsive output variants.
My role
Independent project developer, implementing the Go API and processing pipeline alongside the Svelte/TypeScript interface.
Implemented features
- Accepts JPEG/PNG uploads, preserves originals and generates optimized original-format, WebP and AVIF variants.
- Processes jobs asynchronously and exposes job results and downloads through an API usable independently of the web UI.
- Provides a browser workshop for uploading images, choosing profiles and inspecting results.
Engineering decisions
- PostgreSQL job leases and publication fencing coordinate worker recovery and keep incomplete manifests from being published.
- Image processing runs in a child process with a deadline to bound execution time.
- Separates bearer-key API access from operator browser sessions and CSRF protection; originals remain private.
Testing & validation
- Repository tests cover image input limits, orientation/alpha handling, upload authentication, idempotency and concurrent job claims.
- CI defines Go tests and vet checks plus frontend checks, tests and build.
- A disposable local demo produced JPEG, WebP and AVIF outputs from a synthetic landscape during this update. The results illustrate the workflow, not guaranteed compression savings; the full Go test suite was not rerun.
Current scope & limitations
- Designed for trusted single-operator use; not presented as a production-ready multi-tenant service.
- Compression savings depend on the input and selected profile; there is no guaranteed reduction.
- S3-compatible storage, webhooks and CMS integrations are roadmap items, not implemented integrations.
