A Social Media built from scratch using FastAPI, featuring a scalable and secure backend with Github Actions CI/CD pipeline integration.
- 🔗 RESTful API with FastAPI
- 💾 Database: PostgreSQL with SQLModel ORM
- ✅ Data Validation: Pydantic
- 🔄 Database Migrations: Alembic
- 🔐 Secure Endpoints: JWT Authentication
- 🐳 Dockerized Application
- 🛠️ Continuous Integration: GitLab CI/CD Pipeline
- 🧪 Automated Testing: Pytest
- FastAPI - High-performance web framework
- SQLModel - ORM for database interactions
- Pydantic - Data validation and settings management
- Alembic - Database migration tool
- JWT Tokens - Secure authentication & authorization
- PostgreSQL - Relational database
- Docker - Containerized deployment
- Pytest - Automated API testing
- Github Actions CI/CD - Continuous integration and deployment
git clone https://github.com/RathQd/python_fastapi.git
cd python_fastapiCreate a .env file in the root directory and configure your database & JWT settings.
DATABASE_URL= $URL$
SECRET_KEY= $KEY$
ALGORITHM= $ALGO$
ACCESS_TOKEN_EXPIRE_MINUTES= $TIME_IN_MINs$pip install -r requirements.txt
uvicorn app.main:app --reloadalembic upgrade headpytest already integrated with github actions CI/CD. FastAPI provides interactive API docs:
- Swagger UI:
http://localhost:8000/docs - ReDoc:
http://localhost:8000/redoc
This project integrates a Github actions CI/CD pipeline for automated testing and deployment.
Contributions are welcome! Feel free to open issues or submit PRs.
Star ⭐ the repo if you found it useful!