A toy project designed to learn FastAPI, task queue basics, Docker, and Kubernetes.
This project is to learn exploring distributed system concepts and cloud-native architecture. I build a task queue system to demonstrate:
- FastAPI - Building robust REST APIs
- Task Queues - Understanding asynchronous background processing
- Docker & Kubernetes - Containerization and orchestration mechanics
- Python 3.11+
- uv package installer
- Clone the repository:
git clone https://github.com/hjanday/fastapi-taskqueue.git
cd fastapi-taskqueue- Create a virtual environment and install dependencies:
python3 -m venv .venv
source .venv/bin/activate # On Windows: .venv\Scripts\activate
make dev- Copy the environment example:
cp .env.example .envStart the development server:
make runThe API will be available at http://localhost:8000
- Swagger UI: http://localhost:8000/docs
- ReDoc: http://localhost:8000/redoc
make help # Show all available commands
make lint # Run code linter
make format # Format code
make typecheck # Run type checker
make test # Run tests
make test-cov # Run tests with coverage report
make clean # Clean up cache files.
├── apps/
│ ├── api/ # FastAPI control plane
│ └── worker/ # Task worker (coming soon)
├── infra/
│ └── k8s/ # Kubernetes manifests (coming soon)
├── docs/ # Documentation
├── tests/ # Test suite
├── pyproject.toml # Project configuration
├── Makefile # Common development commands
└── .env.example # Environment variables template
Run the test suite:
make testRun with coverage:
make test-cov