https://github.com/tameronline/mystrotamer-fastapi-docker
A FastAPI-based web application with Docker support and CI/CD pipeline integration
https://github.com/tameronline/mystrotamer-fastapi-docker
api-development ci-cd docker fastapi postgresql python scalable-applications
Last synced: 2 months ago
JSON representation
A FastAPI-based web application with Docker support and CI/CD pipeline integration
- Host: GitHub
- URL: https://github.com/tameronline/mystrotamer-fastapi-docker
- Owner: TamerOnLine
- License: mit
- Created: 2024-11-24T19:06:59.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-11-25T03:03:45.000Z (over 1 year ago)
- Last Synced: 2025-10-21T14:50:26.577Z (8 months ago)
- Topics: api-development, ci-cd, docker, fastapi, postgresql, python, scalable-applications
- Language: Python
- Homepage: https://tameronline.github.io/MystroTamer-FastAPI-Docker/
- Size: 23.4 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 8
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Scalable FastAPI Application with Docker and PostgreSQL Integration
## Overview
This project demonstrates a scalable API solution using FastAPI, Docker, and PostgreSQL. It includes CI/CD integration via GitHub Actions to ensure code quality and smooth deployments.
## Project Structure
```plaintext
mystrotamer-FastAPI-Docker/
├── app/
│ ├── __init__.py # Initialize the app module
│ ├── main.py # FastAPI main application file
│ ├── Dockerfile # Docker configuration for the app
│ ├── requirements.txt # Python dependencies
│ ├── wait-for-it.sh # Script to wait for dependencies
├── db/
│ ├── init.sql # SQL script for database initialization
│ ├── Dockerfile # Docker configuration for the database
├── tests/
│ ├── __init__.py # Initialize the tests module
│ ├── test_main.py # Test cases for the main app
├── docker-compose.yml # Docker Compose configuration
├── .env.example # Example environment variables
├── LICENSE # Project license
└── README.md # Project documentation
```
## Technologies Used
- **FastAPI**: For building modern and fast APIs.
- **Docker & Docker Compose**: To simplify deployment and runtime environment using containers.
- **PostgreSQL**: A robust relational database system.
- **GitHub Actions**: For CI/CD automation.
## Setup and Installation
1. Clone this repository:
```bash
git clone https://github.com/TamerOnLine/MystroTamer-FastAPI-Docker.git
```
2. Navigate to the project directory:
```bash
cd MystroTamer-FastAPI-Docker
```
3. Copy the `.env.example` file to `.env` and update the environment variables as needed.
4. Start the services using Docker Compose:
```bash
docker-compose up --build
```
5. Access the application at `http://localhost:8000`.
## Running Tests
Run the following command to execute the tests:
```bash
pytest tests/
```
## Future Improvements
- Add Redis for caching.
- Integrate user authentication and authorization.
- Deploy the application on a cloud platform like AWS or Azure.
## 🤝 Contributing
- Open an issue if you encounter bugs or have suggestions.
- Submit a pull request for any improvements or new features.
## License
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.