This project is a simple URL shortener that allows users to create short URLs for long URLs. The backend is implemented using FastAPI and SQLModel, and the frontend is implemented using Vue.js.
This is a basic implementation intended to be used as a learning resource. It is not production-ready.
The data is stored in a PostgreSQL database and there is a Redis cache to store the short URLs for faster retrieval.
From the root directory, run the following commands:
docker compose up -d --build
If you want to reload the application, you can run:
docker compose down --remove-orphans && docker compose up -d --build
This will start the FastAPI server and the Vue.js frontend. The frontend will be available at http://localhost:8080
.
This will also start a PostgreSQL database that will be used to store the URLs.
We could implement rate limiting to prevent users from creating too many short URLs in a short period of time. This would help prevent abuse of the service.
Say hello!