URL shortener written in Golang and ReactJS. Inspired by Bit.ly, TinyURL.
- Pet/homebrew
- Expiremental
- Education
- Research
- Hacking
Semi-production ready :)
WORK IN PROGRESS
The project is at an very early stage of development. Breaking changes may occur at any time.
- semantic versioning
- api stabilization
- tests for api
- frontend
- migration to the microservice stack
Mainly for educational purposes. It's a pet/homebrew project, like the ones you can try to create on your own.
This project represents one of the many possible approaches to creating production-grade scalable 3-tier architecture web applications.
Junior/middle software developers may use it for self-education and gaining new skills.
The best way is to fork it. You can take a closer look at the code in your favorite editor. Try to run it and play around with it. If you have a suggestion how to make the project better, create an issue. Pull requests are welcome too.
- Simplicity
- Easy deployment
- Scalable
- Cloud-ready
- Web: Golang/Chi router
- Caching: Memcached
- Persistent storage (Database): PostgreSQL
- Frontend: React
- Public endpoint for shortening links
- Single redirect endpoint
- Sign-in, sign-up functionality
- HTTPS support
- Deployable with Heroku or Docker
- JWT (JSON Web Tokens) authentication
- Private REST API for managing links
- Support for cache engines: in-memory, Memcached, BoltDB
- Multitenancy, users and roles management (RBAC)
- Billing functionality with Stripe
- Prometheus monitoring integration
- Statistics aggregation (coming soon)
- Kubernetes-ready (coming soon)
Using TLS with server
openssl genrsa -out server.key 2048
openssl ecparam -genkey -name secp384r1 -out server.key
openssl req -new -x509 -sha256 -key server.key -out server.crt -days 3650
docker pull stanyx/shortly
docker run --expose=[port] -p [port]:[port] shortly