Zestic Asset Server is a modern, high-performance server for managing and delivering digital assets (such as images, documents, and other files). It is designed to serve uploaded assets efficiently, with built-in support for on-the-fly image manipulation via URL parameters.
- Asset Delivery: Serve uploaded files and images directly via HTTP endpoints.
- Image Manipulation: Transform images (resize, crop, format, watermark, etc.) using simple URL parameters, powered by league/glide.
- Secure Access: Optional support for signed URLs and access control.
- Modern PHP Stack: Built with PHP 8.4, FrankenPHP, and Mezzio for performance and flexibility.
- Dockerized Development: Consistent local development with Docker Compose.
- Extensible: Easily add new asset types, storage backends, or processing features.
-
Start the development environment:
docker compose up -d
-
Install dependencies:
docker compose exec asset-server composer install -
Upload assets:
- Use the provided upload endpoint or place files in the configured storage directory (see documentation or config).
-
Access assets:
http://localhost:8188/{filename}- For images, you can manipulate them on-the-fly:
http://localhost:8188/{filename}?w=400&h=300&fit=cover- See Glide API docs for all supported parameters.
Original image:
http://localhost:8188//photo.jpg
Resized image (width 400px):
http://localhost:8188//photo.jpg?w=400
Cropped and converted to PNG:
http://localhost:8188//photo.jpg?w=200&h=200&fit=crop&fm=png
- Storage: Configure the asset storage location in
config/autoload/glide.global.phpor your environment variables. - Image Processing: All image manipulation is handled by league/glide, which supports resizing, cropping, format conversion, and more.
- Security: Enable signed URLs for secure access if needed.
All development tools run inside the Docker container:
# Run code style, static analysis, and tests
docker compose exec asset-server composer check
# Individual tools
docker compose exec asset-server composer cs-check # Code style check
docker compose exec asset-server composer cs-fix # Code style fix
docker compose exec asset-server composer test # Unit tests
docker compose exec asset-server composer static-analysis # Static analysis- Ensure Docker is running and containers are healthy:
docker compose ps
- Check container logs:
docker compose logs
- Try rebuilding the containers:
docker compose down docker compose up -d --build
- Clear Composer's cache:
docker compose exec asset-server composer clear-cache
This project uses league/glide for all image processing. Glide is a fast, easy, and open-source image manipulation library for PHP, designed to be secure and production-ready.
See LICENSE.md.