yet another link shortening service 🚀
- Rust 1.70+
- PostgreSQL 12+
docker-compose -f compose.yml -f compose.dev.yml upIncludes PostgreSQL + app with local build:
- PostgreSQL:
localhost:5432 - App:
localhost:8080
# Set your database URL
export DATABASE_URL="postgres://user:pass@your-db.example.com/shortener"
export BASE_URL="https://short.example.com"
export DB_MAX_CONNECTIONS=50 # tune for your load
docker compose upUses pre-built image from GHCR (multi-platform: amd64, arm64). Falls back to defaults if env vars not set.
Performance Tuning:
DB_MAX_CONNECTIONS=50for typical workloadsDB_MAX_CONNECTIONS=100+for high concurrency (10k+ concurrent requests)
export DATABASE_URL="postgres://postgres:@localhost/shortener"
export BASE_URL="http://localhost:8080"
cargo build --release
./target/release/ligiloThe server automatically runs migrations on startup.
Full OpenAPI specification available at: https://taranovegor.github.io/ligilo/
Interactive API documentation with endpoint details, request/response examples, and SSRF protection details.
curl -X POST http://localhost:8080/api/links \
-H "Content-Type: application/json" \
-d '{"url": "https://example.com/very/long/path"}'Response:
{
"code": "V1StGXR8",
"short_url": "http://localhost:8080/V1StGXR8"
}curl -L http://localhost:8080/V1StGXR8See CLAUDE.md for detailed technical documentation.
MIT License — see LICENSE for details.