FastAPI App ๐Ÿš€

This repository contains a FastAPI application with Docker Compose setup for a PostgreSQL database and pgAdmin.

Docker Compose ๐Ÿณ

Services ๐Ÿ› ๏ธ

  • postgres-container: PostgreSQL database container.
  • pgadmin: pgAdmin container for database management.
  • fastapi: FastAPI application container.

Ports ๐ŸŒ

  • PostgreSQL: 5432
  • pgAdmin: 8888
  • FastAPI: 8000

Environment Variables ๐Ÿงช

  • PostgreSQL:

    • POSTGRES_USER: semah
    • POSTGRES_PASSWORD: semah
  • pgAdmin:

Dockerfile ๐Ÿ‹

The Dockerfile sets up the FastAPI application.

main.py ๐Ÿšฆ

The main FastAPI application code.

requirements.txt ๐Ÿ“‹

Dependencies for the FastAPI application.

Usage ๐Ÿš€

  1. Clone the repository: git clone https://github.com/semahkadri/FastAPI-app.git

  2. Navigate to the project directory: cd FastAPI-app

  3. Build and run the Docker containers: docker-compose up --build

  4. Access FastAPI at http://localhost:8000.

  5. Access pgAdmin at http://localhost:8888 with credentials: